Forum Discussion

HD's avatar
HD
Contributor
11 years ago
Solved

Namemapping nightmare

Hi, I am new to Testcomplete and having trouble with namemapping. I am using Testcomplete to test a WPF based application. The issue is that UI on the application keeps changing, and each time ...
  • jose_pita's avatar
    11 years ago
    Forget name mapping and use small scripts that search your entire app for the object you need, sending as parameters the properties they have, for example (this works for me because i'm testing a webapp, but I think it works for anything):



    function clickObject(propName, propValue,depthOfSearch)

    {

        Sys.Process("yourApp").FindChild(propName,propValue,depthOfSearch).click(0,0);

    }



    Now you can use this for any action your object supports, use object spy to see all the details about the object you're looking for.



    This solves your issue because it always finds your object, unless their properties change, wich they shoudn't.



    Name mapping is only usable if your app will never change, otherwise you need to take a crash course on how to be able to configure it to work with wildcards and stuff....