成免费的crm,久久国产精品新农夫导航新妓网,恋夜秀场全部视频安卓手机,女校花强奷在线播放A级

ASP OpenTextFile 方法

asp opentextfile 方法

filesystemobject 對(duì)象參考手冊(cè) 完整的 filesystemobject 對(duì)象參考手冊(cè)

opentextfile 方法打開(kāi)指定的文件,并返回可用來(lái)訪問(wèn)此文件的 textstream 對(duì)象。

語(yǔ)法

filesystemobject.opentextfile(fname,mode,create,format)

參數(shù) 描述
fname 必需的。要打開(kāi)的文件的名稱(chēng)。
mode 可選的。如何打開(kāi)文件。
1=forreading - 打開(kāi)文件用于讀取數(shù)據(jù)。您無(wú)法向此文件寫(xiě)數(shù)據(jù)。
2=forwriting - 打開(kāi)文件用于寫(xiě)數(shù)據(jù)。
8=forappending - 打開(kāi)文件,并向文件的末尾寫(xiě)數(shù)據(jù)。
create 可選的。設(shè)置如果文件名不存在,是否創(chuàng)建新文件。true 指示可創(chuàng)建新文件,false 指示新文件不會(huì)被創(chuàng)建。false 是默認(rèn)的。
format 可選的。文件的格式。
0=tristatefalse - 以 ascii 打開(kāi)文件。默認(rèn)。
-1=tristatetrue - 以 unicode 打開(kāi)文件。
-2=tristateusedefault - 使用系統(tǒng)默認(rèn)格式打開(kāi)文件。

實(shí)例

<%
dim fs,f
set fs=server.createobject("scripting.filesystemobject")
set f=fs.opentextfile(server.mappath("testread.txt"),8,true)
f.writeline("this text will be added to the end of file")
f.close
set f=nothing
set fs=nothing
%>

filesystemobject 對(duì)象參考手冊(cè) 完整的 filesystemobject 對(duì)象參考手冊(cè)
相關(guān)文章