How to capture screenshots of Exceptions/Errors during run-
time?
Answer Posted / ravi_kanakam
When error occurs you can take screenshot of the desktop
and send the bitmap to result file.
if error occurs then
Desktop.CaptureBitmap("c:\bitmap.bmp")
Reporter.ReportEvent micFail, "Error Name", "<<img
src="c:\bitmap.bmp>"
end if
The above code will send the screen shot to the Result File.
| Is This Answer Correct ? | 8 Yes | 1 No |
Post New Answer View All Answers
What ate the Technologies supported by QTP?
How to replay a script in qtp?
What is the basic concept of quicktest professional?
What are the two types of repositories available, explain them?
I have 5 save buttons in 5 tabs . The tabs are placed one after the other. My object repository have these added as 5 save buttons with name sav1, save 2, save 3 , save 4, save 5 .all are getting highlighted from OR but they are not getting clicked. After spying each button all the properties are same except First button Index 0 html id:=btnSaveTab1 outerhtml:=", Second button "html id:=btnSave "outerhtml:=", Third button "html id:=", outerhtml:=",
How many types of status are there?
We stored into the objects OR and then write the scripting
What are the trigger events in qtp?
You will receive the mail in your outlook from client at night time to go ahead for the execution. Based on the mail you need to trigger the batch run. What is the QTP Code for this?
Explain how you can find length of array in qtp?
Connect to QC using AOM.
What are the ways you can synchronize?
if our qtp vb Script may be Currepted then What we want do?
Can you write a script to check if the folder exists or not?
Explain about the quicktest professional (qtp) automation object model?