How to create log file in qtp?
Answers were Sorted based on User's Feedback
Answer / naveen
Using CreateTextFile method of File System Object property.
we can create a log file and write the data into it.
Sub CreateAfile
Dim fso, MyFile
Set fso = CreateObject("Scripting.FileSystemObject")
Set MyFile = fso.CreateTextFile("c:\testfile.txt", True)
MyFile.WriteLine("This is a test.")
MyFile.Close
End Sub
| Is This Answer Correct ? | 7 Yes | 4 No |
Answer / keerthykannan
Dim fso,objLogFile
Set fso = CreateObject("Scripting.FileSystemObject")
Set objLogFile = fso.OpenTextFile ("C:\Log" &var
&".txt",2,true)
objLogFile.Writeline(time)
objLogFile.Close
| Is This Answer Correct ? | 2 Yes | 1 No |
Why do you choose only QTP for your project automation among remaining tools like Rational robot and silk test?
What are the methods used in UFT to handle exceptions or run-time errors?
How QA specialist can identify when programmatic descriptions are useful?
What is data driver in qtp? Where we use it?
How many ways we can parameterize data in quicktest professional?
What is the another extention name of library file.If that is exist than what's the differnce between them.
what kind of erros can be handled with the using QTP?
Is it possible to split an action? How?
can we install qtp in windows vista
How we test the logo or images in the web page using QTP? For example take google page, they change their logo for new year,christmas etc..How we test that? Plz answer this question... Thanks in advance..
What is difference between design time and run time data table?
you written some code in qtp for opening google.com browser and entered some text inthe search text box and clicked search button. this is ur script.. before running this script i have already opened two google.com browsers. now am running the script what will happen? script will run or what?? Thanks... Nani