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 capture screen shots when an error occurs?

Answer Posted / deepak k

Hi use RecoveryFunction to capture the image when error
ocours.

Step1: Create a VBS file using following founction
Function RecoveryFunction1(Object, Method, Arguments,
retVal)

'Find the Test Folder Path
Set qtApp = CreateObject("QuickTest.Application")
testpath = qtApp.Folders.item(1)
'stores the image inside the test folder
image_name= testpath &"\imagename.png"
Desktop.CaptureBitmap image_name
End Function

Step2: Go to Recovery manager
step3: select "On Any error" or select u r own option
Step4: select function to call
step5: call the above mentioned file

Rest QTP will do it for you

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What are the challenges u faced in testing with crm domain? How u overcome with?

1940


Which environments are supported by hp qtp?

996


Mention the different actions types of qtp.

1012


Explain the concept of object repository and how quicktest professional recognises objects?

1018


How you can decide which type of object repository you have to use?

1189


What are the 3 main stages involved in testing with qtp?

1082


What is the difference between run time object and test object in QTP?

1051


How to use reporter.report event in qtp ?

1033


Explain the types of object repositorys in qtp?

1088


What is expert view in qtp?

1057


What is reusable action?

1089


How many types of parameters are there?

985


In an interview, what r the general questions asked in QTP? pls give me anwser to this question?

1877


Does Low-level recording capture mouse movements?

1041


In keyward driven framework what will be the step for yahoo login page ,inbox logout,plz explain in detail

2063