Page 1 of 1

-

Posted: Mon Nov 25, 2002 6:46 am
by Thunderhawk66
-

Re: Loading text files

Posted: Mon Nov 25, 2002 3:21 pm
by frankiebaby
Ok well, the easiest way, if you only want to display lines on screen, is to use

OPEN "file.fle" FOR INPUT AS #1
FOR
line input #1, TEXT$
PRINT TEXT$
NEXT


you can also try input# for space or comma delimited values.

in the online help:

LINE INPUT # - a file I/O statement that reads an entire line without delimiters from a sequential file to a string variable

Syntax
LINE INPUT #filenumber,stringvariable
  _ filenumber is the number of an open sequential file
  _ stringvariable will hold all characters from the
       sequential file from the current position
       in the file up to, but not including, the
     next carriage-return-line-feed sequence. No
      carriage-return-line-feed
     sequences are ever input.