ASP 讀取 TXT 文字檔
<html><head>
<title></title>
</head>
<body>
<%
Set fs = CreateObject("Scripting.FileSystemObject")
Set ts = fs.OpenTextFile ("c:\MyText.txt")
'只會讀取第一行的資料
Do While ts.AtEndOfLine <> True
Response.write ts.Read(1)
ts.skip(1)
Loop
ts.Close
%>
</body>
</html>
頁:
[1]