Forum Discussion

Jager's avatar
Jager
New Contributor
8 years ago

TestComplete doesn't recognize good submit

Hi,

 

I have 2 submit's near themselves. Unfortunately TestComplete click the wrong submit, what should i do? 

2 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor

    TestComplete will click on the submit button that, using the parameters given to it in the NameMapping/Aliases section or other code (such as FindChild or FindAllChildren), it finds FIRST in making that determination.  It seems that your problem is indicative of a bit of ambiguity in distinguishing the two submit buttons.  Take a look at your mapping parameters for those buttons and see if there are additional properties you can add to make a more accurate distinction such as particular text in the innerText  property, labels or ids that are unique, etc.

    • Colin_McCrae's avatar
      Colin_McCrae
      Community Hero

      You should tell us HOW you are trying to click on it, then we can give you a better idea how to fix it.

       

      Are you using name maps or finds or a combination of both?

       

      And some additional context might be helpful as well. Are there always two submit buttons? Do they submit the same thing? Will you need to use them both at some point? etc etc ....

       

      The devil is in the detail. And at the moment, we have very little detail ...