SPONSORS:






User Tag List

Thanks Thanks:  0
Likes Likes:  0
Dislikes Dislikes:  0
Results 1 to 4 of 4
  1. #1
    Member
    Join Date
    Sep 2002
    Location
    Hyderabad
    Posts
    34
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Retrieving the HTTP ERROR CODE

    Hi
    Iam facing some problem in retrieving the HTML error code of a page.
    Ex: Say if a page is not there u get 404 as error code. But the same error page may not be displayed.
    My QTN is how to capture the HTTP error code of a page(if any) using AQT
    Pls reply at the earliest
    Gururaj Joshi

    ------------------

  2. #2
    Junior Member
    Join Date
    May 2003
    Location
    Belgium
    Posts
    8
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Retrieving the HTTP ERROR CODE

    Nobody ever seems to have answered the question above, so I'ld like to repost it. I have a web-application that frequently returns HTTP 500 errors. This can appear on any page. I'ld like to check the http return code on the screen each time the script navigates to a new window.

    I could rather easily create a function that does a GUI check to see whether an error has occurred. However, I can imagine that it would also be possible to create a function that checks the HTTP return code itself (like in LoadRunner). Anyone has an idea how to achieve this last possibility?

    Regards and thanks in advance!

    Jorge

  3. #3
    Senior Member
    Join Date
    Oct 2001
    Posts
    189
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Retrieving the HTTP ERROR CODE

    Hi Gururaj,

    QTP doesn't have any function to get directly the HTTP error code. You can do this only by getting the page innerHTML and search it for the specified error, if it finds log an error. You can create generalised function to do this.

    Thanks
    Satya

  4. #4
    Moderator
    Join Date
    Sep 2001
    Location
    Doncaster, UK
    Posts
    5,788
    Post Thanks / Like
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Total Downloaded
    0

    Re: Retrieving the HTTP ERROR CODE

    Guruaj the problem with HTTP error codes is that they are trapped at the server-side (e.g. IIS).

    As QTP is concerned by client-side processes and not server side (like LoadRunner) it doesn't seem to be directly accessible from QTP (don't know if WSH or VBS can access the information).

    You can access the server-side logs and peruse them but it's quite labour intensive.

    Mark.

 

 

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 10.71%
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 03:59 AM.

Copyright BetaSoft Inc.