w3pop.com :: 网络学院 :: ASP :: ASP Write 方法
The Write method writes a specified text to a TextStream file.
ASP Write方法的主要作用是向文本文件中写一段指定的文本。
Note: This method write text to the TextStream file with no spaces or line breaks between each string.
注意:这个方法的作用是向一个文本文件中书写一段文本,但是在每个字符串之间不包含空格和换行这两个属性。
| TextStreamObject.Write(text) |
| Parameter 参数 |
Description 描述 |
|---|---|
| text | Required. The text to write to the file 必要参数。向文本文件中书写文本 |
<%
dim fs,f
set fs=Server.CreateObject("Scripting.FileSystemObject")
set f=fs.CreateTextFile("c:test.txt",true)
f.write("Hello World!")
f.write("How are you today?")
f.close
set f=nothing
set fs=nothing
%>
The file test.txt will look like this after executing the code above: Hello World!How are you today? |
评论 (0)
All