A text file that is partitioned into an unlimited number of uniform-length compartments called records. When you open a random-access text file for the first time, you must specify its record length. No record is placed in the file until written to. Each record can be individually read from or written to—hence, random-access. Compare sequntial-access text file.