1. how can you handle exceptions without using recovery
scenario?

Answers were Sorted based on User's Feedback



1. how can you handle exceptions without using recovery scenario?..

Answer / narender reddy alala

by using "on error resume next" we can handle exceptions

Is This Answer Correct ?    8 Yes 0 No

1. how can you handle exceptions without using recovery scenario?..

Answer / baba

Hello buddy,

If the Error is predictable... You know that Test Script
has an error, while running the script the error will come.

Here, you can use "On Error Resume Next"

On Error Resume Next
Err.Raise 6 ' Raise an overflow error.
MsgBox "Error # " & CStr(Err.Number) & " " & Err.Description
Err.Clear ' Clear the error.

here
e.g.
On Error Resume Next
msbox "Hello"
Msgbox err.number&err.description

try this it will give one "Number and Description" output
you submit in 1st code given by me instead of 6.

If Any Unpredictable Errors/Events occur You cannot guess
where and when they will come. then you should go for the
Recovery Scenario Manager.

Thanks & Regards
Baba.D contact kingring.d@gmail.com

Is This Answer Correct ?    8 Yes 0 No

1. how can you handle exceptions without using recovery scenario?..

Answer / pankaj sharma

We can also use cases if the points where error is suppose
to throw .
like
if Err.Number = 12 then
systemutil.closeprocessbyname "processname"
call function()
end if

To discuss more about this or some other topic please visit
http://quality2deliver.blogspot.com/

Is This Answer Correct ?    0 Yes 0 No

1. how can you handle exceptions without using recovery scenario?..

Answer / dinesh

using the optionalstep method we can handle the error.

Is This Answer Correct ?    0 Yes 0 No

1. how can you handle exceptions without using recovery scenario?..

Answer / vengi

by using on resume next

Is This Answer Correct ?    0 Yes 5 No

Post New Answer

More QTP Interview Questions

What is the Diff between Image check-point and Bit map Check point?

3 Answers   Crea,


I'm facing this problem while automating my application..its a web based apps.. In my application there are few webtables are displaying in the page.In the different cells there are links and action buttons.Problem is there is link in different web tables corresponding to one name.Hence the properties of the objects(say a link) are same except the x,y co ordinate of the object.So my script is not able to distinguish between the two links present in different cells of web tables with same name.Kindly help on this..

3 Answers  


give me descriptive programing code sample flight application in qtp?

8 Answers   CA, IBM,


How can we use regular expressions for a table in web page, each cell in table having unique identification, Now I want to count number of rows in table and enter data in all cells of the table?

1 Answers   CTS,


what is the difference between parameters and arguments?

1 Answers  






Login to flight app, in window flight reservation set the date field and select flyfrom as Frankfurt and verify whether flyto list box has the item FrankFurt, log the results.

1 Answers   Cap Gemini,


How to invoke QTP through VBscript?Send me full code along with description of the code.Thanks in Advance

1 Answers   Capco,


How to find which type of Framework is suitable for which type of application?

4 Answers   CTS,


Do you know how to connect database? Can you tell me the procedures?

0 Answers  


what are the principles of good testing scripts for automation?

1 Answers  


How do u write a regular expression for date (dd/mm/yyyy) field?

10 Answers  


how can you write a script without using GUI in QTP?

5 Answers   Ordain Solutions,


Categories