Function ReadLine(pathway, rowcount)
Dim fso,myfile,i,flag
flag = 1
Set fso=CreateObject("scripting.FileSystemObject")
If fso.FileExists(pathway) then
Set myfile = fso.openTextFile(pathway,1,false)
Else
flag = 0
End If
For i=1 to rowcount-1
If Not myfile.AtEndOfLine Then
myfile.SkipLine
tempp = myfile.Line
End If
Next
If flag = 1 Then
If Not myfile.AtEndOfLine Then
ReadLine = myfile.ReadLine
Else
ReadLine = "overflow"
'ReadLine = myfile.ReadLine
End If
myfile.close
Else
ReadLine = "file not exist"
End If
End Function作者: yuandjing 时间: 2009-1-22 17:29
发现问题了,只要把html的那行空行去掉就OK了
难道空行会影响?奇怪了作者: honsongj 时间: 2009-1-22 20:12
出乎意料作者: yuandjing 时间: 2009-1-23 10:15
Dim fso,myfile
Set fso=CreateObject("scripting.FileSystemObject")
Set myfile = fso.openTextFile(fileFullPath,1,false)
temp = myfile.ReadAll
MsgBox temp