Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...


How to create log file in qtp?

Answers were Sorted based on User's Feedback



How to create log file in qtp?..

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

How to create log file in qtp?..

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

Post New Answer

More QTP Interview Questions

How to use output values in qtp ?

0 Answers  


wht is Automation testing frame work. pls explain it

3 Answers   Wipro,


What is recovery scenario in qtp?

0 Answers  


how to test background color and dynamic images during runtime

4 Answers   Accenture, Oracle,


What is the Command used to start the QTP

0 Answers   HCL,


Why QTP is termed as a Record and Playback tool?

1 Answers  


Could any one explain about the nested actions in QTP? This question is asked by Qualitree and CA

3 Answers   CA, Qualtree Solutions,


If 3 browsers are opened in our system, how to enter the facebook url into second browser by using descriptive programing

3 Answers   Mind Tree,


Can any one give me some basic VB script used in QTP ?As i am new in QTP.Give sample VB script used in QTP? PLZ

3 Answers  


you are recording on "WINDOW 1", say it has a link if you click on that, that leads you to "WINDOW 2". If you do any manipulations on "WINDOW 2" that are automatically updated in to "WINDOW 1". But "WINDOW 1" is currently invisible. But the updations in "WINDOW 1" must also be recorded as a script in QTP. The best Example is if you update your resume in JOB STREET portal it actually happens in other window, but the previous window is automatically updated. Now does QTP help you in this types of situations? Any body can answer this question. please..... Siva

0 Answers   Covansys,


What is the difference between qtp and selenium?

0 Answers  


qtp script for recording and running the application.need script for short cut keys like f3,f4 etc.how to write script for recording?

2 Answers  


Categories