Forum Discussion

Veldeni's avatar
Veldeni
Occasional Contributor
13 years ago

KeyWordtest waiting for a window and button which is right there!

Hi my problem is is that sometimes (can not figure out when it does recognise the window and button) TestComplete just does not see the window and button. I am testing an uninstall and the window appears are you sure with a no and yes button. In the upper right corner I see Testcomplete saying "waiting for button yes to appear". It is right there!!!

I use keyword test because I am no coder but that was the whole upside of testcomplete that you do not have to be one. Can anyone give me advice besides learning to become a programmer, to help Testcomplete recognize this window?



thanks in advance.

5 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    The problem may be in the NameMapping of the window with the button and the button itself.  Your keyword test is looking to see if the reference in the test in Aliases exists... the "Waiting for" is TestComplete telling you that it's trying to find it.  Apparently, it's not.  so, this means you need to investigate the NameMapping for the button and/or the window.



    Another possibility may not necessarily be with recognition of the button but with what I call "timing issues".  The scripts are executing at full speed without wait time.  However, between one step and another, the application being tested may have a delay before the next screen shows up.  This could cause recognition errors.



    As a test, before the test where the button needs to be clicked, put a "Delay" action in place.  The other thing you might want to do is add an "If Object" action in before the button to do a test to make sure the window with the button exists before you try and click the button.  No coding necessary, but these kinds of timing issues and recognition issues happen no matter what tool you're using and whether or not you're using code or keyword tests.
  • Veldeni's avatar
    Veldeni
    Occasional Contributor
    Thank you for your reply Martin. I already have a delay on every click because I soon found out that the automated install goes through the actions very fast. So the problem must be because of the window finding issue. Thanks again
  • Veldeni's avatar
    Veldeni
    Occasional Contributor
    So I have recreated my test and I also did the name mapping tutorial but there is no obvious reason why it does not find my "next "button.

    It says 


    Tested Object

    Alias: Aliases.setup.dlg.btnNext 

    Mapping item: NameMapping.Sys.setup.dlg.btnNext 





    Missing Object

    Alias: Aliases.setup.dlg.btnNext 

    Mapping item: NameMapping.Sys.setup.dlg.btnNext 




    If I check with the object finder that is exactly what it is called. Any other options?