Forum Discussion

Darina's avatar
Darina
New Contributor
13 years ago

Property name in web application.

Hello,

 we use the TestComplete 8.6.

To find the html components on the page we use FindChild( Name, ControlName, 7) (for example). In this regard, there are problems, if any components have the same name (or haven't any name) but on different levels, Label (0) for example. The developers of the project raised the question - as is formed in TestComplete property Name, from any html property in the test application. 



Thank you,

Darya.

1 Reply

  • irina_lukina's avatar
    irina_lukina
    Super Contributor

    Hi Darya,


    As far as I understand, your question is: which object will be returned by the FindChild method if there are several objects (on different levels) that correspond to the search criterion? In this case, the FindChild method will iterate through the objects hierarchy tree from the specified parent object and will return the first found object that meets the specified criterion.


    To improve the search (so that it finds the needed object but not the first found), I'd recommend that you specify a more detailed search criterion or change the search depth used by the method.


    I hope this is what you were looking for :)