Latest web development tutorials

ASP AtEndOfLine property

TextStream Object Reference Complete TextStream Object Reference

AtEndOfLine property returns a Boolean value. True indicates that the file pointer before the close TextStream file marks the end of the rows, otherwise False.

Note: This property only works in read-only open TextStream object.

grammar

TextStreamObject.AtEndOfLine

Examples

<%
dim fs,f,t,x
set fs=Server.CreateObject("Scripting.FileSystemObject")
set f=fs.CreateTextFile("c:\test.txt")
f.write("Hello World!")
f.close

set t=fs.OpenTextFile("c:\test.txt",1,false)
do while t.AtEndOfLine<>true
x=t.Read(1)
loop
t.close
Response.Write("The last character is: " & x)
%>

输出:

The last character of the first line in the text file is: !


TextStream Object Reference Complete TextStream Object Reference