When we use 'ERR' object to handle the exceptions in the
script, do we need to include any statement in the
beginning of the script..??
Answers were Sorted based on User's Feedback
Answer / uday kumar _ anem
Generally, when QTP encounters a run time error during
running the scripts, it shows the error message in a pop up
window and the script execution will stops.
If you wish to display your own error message and you wish
to continue with the script, then we will use Err object.
We have to use "On Error Resume Next" statement before the
runtime error is returned.
The general usage of the Err object is like:
On Error Resume Next
dim fileSysObj
fileSysObj=createobject("Scripting.FileSystemObject")
fileSysObj.folderexists("c:\uday") 'assume this folder
doesnt exist
'QTP shows the error message here itself and stops
execution, if "On Error Resume Next" statement doesnt exists
If Err.Number <>0 then
msgbox("Here it prints") 'Because of Err object we can give
our own error message
end if
Is This Answer Correct ? | 1 Yes | 1 No |
Answer / nath t
Yes u have to mention "On Error Resume Next" statement in
the beginning of the script
Is This Answer Correct ? | 0 Yes | 1 No |
What does SPLIT and JOIN commands do in Vbscript?
6 Answers Ordain Solutions, UBC,
How to connect QTP to Testdirector
What are the technologies supported by qtp?
what is the main process in QTP?
Hai Guys, can anybody show me how to write automaed test cases using VB scprit(examples)...i had an interviw soon...please guyz send as quickly as possible
What is Object Spy in QTP?
Did QTP prove efficient for your project? Yes or No, explain?
what r the verstions from 1st to present (verstions) of mercury tools (like winrunner,QTP,Loadrunner) ? Chandana
0 Answers Mannar Company, Wipro,
I have made the recovery scenario in script. When i am exceuting the script. it stop automatically after running recovery scenario. Please tell the resaon?
When QTP object wait time is 10 seconds, and in test script wait time is 5 seconds and in function library wait time is 2 seconds how much time does the wait occur? or which is given priority.
How can i open 5 multiple browser at once through QTP VB script and i want to login with 5 different credentials i already tried with this code but its entering credentials only for first browser and am using datatable to parameterize
Can we test the Word Document using QTP Tool? We should test the page size,page set up, paragraph indentation and spacing, font size of the the character int the page.