Detecting end of line and end of file while using the .Read() method 
Author Message
 Detecting end of line and end of file while using the .Read() method

I am using the Read() and ReadLine() methods to get the text from a text
file. I just recently learned how to do this, but I have used Javascript to
search long strings character by character in the past. When I searched
strings in the past, I used an if statement to test if each character was
equal to "\n", and eventually concluded that there was a "\r\n" between the
end and beginning of each line. However, this does not seem to be true for
reading from a text file (I tried testing for "\n" and testing for "\r", but
niether one seemed to be there). In a class I once took, there were specific
codes (I believe the end of line one was EOL) for end of line and end of
file. How do you do it in Javascript?
--
Nathan Sokalski

http://www.*-*-*.com/


Sun, 29 Feb 2004 13:56:15 GMT  
 
 [ 1 post ] 

 Relevant Pages 

1. Method to Read the latest line, in the end of file

2. Different line ends/segment ends on dashed line?

3. Different line ends/segment ends on dashed line?

4. how to detect end of line in excel workbook

5. how to detect the end of line

6. how to detect end of line in excel workbook

7. Detecting line-end

8. Detecting end of file

9. deleting lines in a file except those with a spesific ending

10. Read text file and send msgbox when end is reached

11. Read from specific string in txt file to end

12. Detecting when a shell command ends.

 

 
Powered by phpBB® Forum Software