SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 5 of 5
  1. #1
    Junior Member
    Join Date
    Dec 2006
    Location
    New Delhi , India
    Posts
    22
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    How to handle Run-time errors?

    Hi,

    How to handle run time error using QTP Recovery scenerio manager...
    Please help me with proper step and a litle Example

    Regards,
    A.khan

  2. #2
    Senior Member
    Join Date
    Dec 2006
    Location
    Germany, Dresden
    Posts
    1,536
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to handle Run-time errors?

    runtime errors should be handledt by the script, not by RecoveryScenarioManager.

    Try
    >On Error Resume Next
    >If Err.Number <> 0 Then 'in case of error...
    > 'code in case of error
    > End If
    > On Error GoTo 0

    Thats all, but it seem a basic in QTP to know something about VBS.

    Another way (found in the Online help of QTP)

    > x = GetLastError
    > MsgBox DescribeResult(x)
    http://qcmt.pc-polis.de

    de omnibus dubitandum

    For all Questions: Please be sure to take a look at the QTP Manual before posting any Questions, thanks for doing this

  3. #3
    Moderator
    Join Date
    Jul 2005
    Location
    Delhi
    Posts
    15,575
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    7 Thread(s)
    Total Downloaded
    0

    Re: How to handle Run-time errors?

    Recovery Scenario is for errors which you know might occur but you dont know where they can occur. You can also use it for any error which you dont know before head but usually not helpful in that case.

  4. #4
    Member
    Join Date
    Jan 2006
    Posts
    31
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to handle Run-time errors?

    With my experience, please prefer to use Err.Description to get the entire error message, not the following script:

    > x = GetLastError
    > MsgBox DescribeResult(x)

  5. #5
    Member
    Join Date
    Feb 2007
    Posts
    347
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: How to handle Run-time errors?

    In my view "Getlasterror" is for capturing qtp errors not the application errors.
    Vishal Aggarwal
    Test Architect
    http://testocean.blogspot.in/

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Search Engine Optimisation provided by DragonByte SEO v2.0.36 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Resources saved on this page: MySQL 6.67%
vBulletin Optimisation provided by vB Optimise v2.6.4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.2.8 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominate (Lite) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Feedback Buttons provided by Advanced Post Thanks / Like (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Username Changing provided by Username Change (Free) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
BetaSoft Inc.
Digital Point modules: Sphinx-based search
All times are GMT -8. The time now is 04:34 AM.

Copyright BetaSoft Inc.