SPONSORS:






User Tag List

Results 1 to 5 of 5
  1. #1
    Member
    Join Date
    May 2003
    Location
    pune
    Posts
    52
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Unexpected error message

    while writing my automation script for web application there is an error message window for internet explorer. it is very uncertain and sometimes it opens and sometimes it doesn't so how to deal such windows because there is no specific place where it is opened. I just want that as soon as this window is opened it whould be closed.It's very important because if this window is not closed then remaining testcases does not run.
    thanks.
    Ramesh

  2. #2
    JCC
    JCC is offline
    Senior Member
    Join Date
    May 2002
    Location
    Copenhagen, Denmark
    Posts
    116
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Unexpected error message

    Hi

    I have had a similar problem recently with a window application.
    One way of solving the problem is using the MessageBoxClass which is automatically declared when you record the declaration of an applications main window. Note! errormessages are normally treated as messageboxes.
    When you write your Test Cases you can check if a messagebox exists by typing something like:

    [-] if (MessageBox.Exists (2))
    [ ] ErrorMessageHandler () //My Default Error handler function automatically close the messagebox and continue with the testcase

    Hope this gives you an idea of how to solve the problem [img]images/icons/smile.gif[/img]

    [ 05-27-2003, 02:29 AM: Message edited by: JCC ]

  3. #3
    Member
    Join Date
    May 2003
    Location
    pune
    Posts
    52
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Unexpected error message

    the thing which u tell is correct if i am knowing where the message box is popped but this is a explorere error window it can pop up any time i can not write the code at each and every line. isn't it correct.
    Ramesh

  4. #4
    JCC
    JCC is offline
    Senior Member
    Join Date
    May 2002
    Location
    Copenhagen, Denmark
    Posts
    116
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Unexpected error message

    No that would not be a good idea [img]images/icons/wink.gif[/img] . However if you put your testcase into a Do...Except statement and in the except part check for error messeages you only need to write a line of code pr do...except statement

    e.g.

    Do
    ... Somthing
    Except
    ErrorHandler() <- in this function you check for unexpected messageboxes, e.g. by using the exists method.

  5. #5
    Member
    Join Date
    May 2003
    Location
    pune
    Posts
    52
    Post Thanks / Like
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Unexpected error message

    that's great i think it will work.
    thanks,
    Ramesh
    Ramesh

 

 

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  

vBulletin Optimisation provided by vB Optimise v2.6.0 Beta 4 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
User Alert System provided by Advanced User Tagging v3.0.9 (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
Questions / Answers Form provided by vBAnswers (Pro) - vBulletin Mods & Addons Copyright © 2016 DragonByte Technologies Ltd.
vBNominatevBulletin 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 09:25 AM.

Copyright BetaSoft Inc.