亚洲乱码中文字幕综合,中国熟女仑乱hd,亚洲精品乱拍国产一区二区三区,一本大道卡一卡二卡三乱码全集资源,又粗又黄又硬又爽的免费视频

如何讀取文本文件的內(nèi)容?

 更新時(shí)間:2006年11月16日 00:00:00   作者:  

<%
Dim write
Dim fileSysObj, tf, read
read = "intels.txt"
'
讀取intels.txt.

read = LEFT(Server.Mappath(Request.ServerVariables("PATH_INFO")), InStrRev(Server.Mappath(Request.ServerVariables("PATH_INFO")), "\")) & read
'
檢索要讀的文件的完整路徑.

Set fileSysObj = createObject("Scripting.FileSystemObject")
'
創(chuàng)建一個(gè) FileSystem Object 實(shí)例,并把它保存到 fileSysObj 的變量中

IF (fileSysObj.FileExists(read)) Then
Set tf = filesysobj.OpenTextFile(read, 1)

' 如果文件在,就打開(kāi)讀取.

read = tf.ReadLine
tf.Close
ELSE
read = "
,找不到這個(gè)文件!"
'
如果文件不存在,發(fā)出錯(cuò)誤提示.
END IF
%>

<html>

<body>

<p align="center">千花飛舞之讀取文本內(nèi)容</p>

 

<div align="center">

<div align="center">
<center>
<table border="0" width="40%" cellspacing="0" cellpadding="0">
<tr>
<td width="100%" bgcolor="green"><B><%=read%></B>
</td>
</tr>
<tr>
<td width="100%">

</table>

</center></div>

</body></html>

相關(guān)文章

最新評(píng)論