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 |
What is the difference between Call to Action and Copy Action?
can we install qtp in windows vista
how are environment variables used in real time projects (testing)?what answer should be given about this in interview.need real time explanation breifly?thnx in advance.
what is error and fault in terms of software quality?
Hi all, I am New to QTP . I am Now in critical situtaion. I want to know How to create our own object respository for our application. please say the answer with example.
Without integrating QC/Testdirector with QTP, is it possible to keep track of the defects?If yes how? How to export QTP results to an excel sheet?
How do you create regression test packs?
what type of application we can select for automation testing and what is the entry criteria for automation
how to parameterise a test with data base table or excel sheet?
How can you write the scripts that operate on different objects depending on run-time information?
Explain about the test fusion report of quicktest professional (qtp)?
when we open flight reservation.at that time where we found synchronization point() and wait function().i m confused .i want this answer.