ASP AtEndOfLineプロパティ
AtEndOfLineプロパティは、ブール値を返します。 Trueの場合、近くにテキストストリームファイルの前にファイルポインタがそうでなければFalse、行の終わりを示すことを示しています。
注:このプロパティは読み取り専用オープンテキストストリームオブジェクトで動作します。
文法
TextStreamObject.AtEndOfLine
例
<%
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: !
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: !
完全なテキストストリームオブジェクトリファレンス