Forum Discussion

chelsea's avatar
chelsea
Occasional Visitor
8 years ago

How can objects be identified in an application if the have the same name, one is visible on isnt?

I am currently testing a WPF Application, I have an object i would like the tool to select but it isnt working, I am currently scripting the tests in Javascripts, this particular object has the same name as another object which is not visible on screen, but for some reason test complete has found the one that is invisible rather than the one displaying on screen, is there a way we can set test complete so it doesnt search for invisible options within an application??

2 Replies

  • tristaanogre's avatar
    tristaanogre
    Esteemed Contributor
    Object recognition, by default, uses the component name. In NameMapping, it is best to modify the maps to utilize more robust criteria that will designate a more unique mapping. Plenty of topics here with lots of suggestions. I'd also recommend reading up on the NameMapping feature
  • Bobik's avatar
    Bobik
    Frequent Contributor

    TestComplete (11.31)  has NameMapping option "Search for  visible objects first". Maybe it will help you.You can find it in Tools|Options dialog, at Engines\Name mapping page.