open "infile" for input as #2 line input #2, inline$ print inline$ close 2
line input StrVar
is the synopsis of the line input statement for disk file input (as described above) when standard input is redirected to a disk file. Although the organization of these manual pages implies the older, less flexible system, this organization is maintained only for convenience, line input and line input # do not differ functionally. The difference in behavior between terminal input and disk file input depends entirely upon the type of file in use.
If FileNum is open for random access, an "Illegal function call" error occurs.
An "Input past end" error occurs when an attempt is made to read beyond the end of the file.
from The Basmark QuickBASIC Programmer’s Manual by Lawrence Leinweber