1. how can you handle exceptions without using recovery
scenario?
Answers were Sorted based on User's Feedback
Answer / narender reddy alala
by using "on error resume next" we can handle exceptions
| Is This Answer Correct ? | 8 Yes | 0 No |
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 |
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 |
Answer / dinesh
using the optionalstep method we can handle the error.
| Is This Answer Correct ? | 0 Yes | 0 No |
How qtp identifies objects?
What are the framework folders?
What is the difference between per-action and shared?
what is recovery scenario in QTP? what is the need of the recovery scenario in QTP? what are the advantages of the recovery scenarios in QTP?
What are the advantages of qtp?
Count the number of radio buttons and randomly select one.
can any one tell me what is process metrics and what is product metrics if possible give me example. Thank You
How to perform cross platform testing and cross browser testing using qtp? Can you explain giving some example?
Can we call qtp test from another test using scripting. Suppose there are 4 tests and I want to call these tests in a main script. Is this possible in qtp?
What issues come up in test automation, and how do you manage them?
What are the Disadvantages of shared object repository?
Hi Guys, My Application in Microsoft Dynamic Navision, is it compitibale with QTP? if yes then let me know...