set objFileToRead = CreatObject("Scripting.FileSystemObject")
Set strReadline=objFileToRead.OpenTextFile(strpath,1)
Do While strReadline.AtEndofStream<>True
strRecordName = Trim(Mid(strReadLine,52,15)
hp-UFT中的第4行面错误运行错误: - 对象不支持此属性或方法
答案 0 :(得分:0)
请粘贴代码而不会出现语法错误。您的代码应该是这样的
strpath="C:\Users\561320\Documents\Saikrishna\caffeine\readme.txt"
set objFileToRead = CreateObject("Scripting.FileSystemObject")
Set strReadline=objFileToRead.OpenTextFile(strpath,1)
Do While strReadline.AtEndofStream<>True
strRecordName = Trim(Mid(strReadLine.Readline,52,15))
Wscript.echo strRecordName
Loop