Search a Word Using QTP

How to search a Word in a document using QTP?

Questions by shyamroyal

Showing Answers 1 - 3 of 3 Answers

md_vinodh

  • May 30th, 2008
 

Please use the code

Function WriteToFile

    Const ForReading = 1, ForWriting = 2
   
    Dim fso, f
   
    Set fso = CreateObject("Scripting.FileSystemObject")

    Set f = fso.OpenTextFile("c:testfile.txt", ForWriting, True) f.Write "Hello world!"

    Set f = fso.OpenTextFile("c:testfile.txt", ForReading) WriteToFile = f.ReadLine

End Function

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions