Forum Discussion

hirospeed's avatar
hirospeed
Occasional Contributor
14 years ago

How to get the number of objects?



Hi



Please check attachments pic,I hava object "m_RootGird",I want to get the number of  "Border"?



Do you have some good method to get the number of objects?Thanks for your help!








3 Replies

  • AlexKaras's avatar
    AlexKaras
    Champion Level 3
    Hi,



    One possible way:

    Use FindAllChildren method (see relevant TC help topic for more details) and use the size of the returned array. Exact code depends on the script language you are using.
  • hirospeed's avatar
    hirospeed
    Occasional Contributor
    Hi,Alexei

     

    I try to use FindAllChildren before write Questions!But I dont find appropriate property!



    for example



    dim arr

    arr=object.FindAllChindren("name","Border")



    Bounds(arr)  return -1



    I cant find them...   How to write ??



    Thanks Alexei
  • hirospeed's avatar
    hirospeed
    Occasional Contributor
    I can do it,I write wrong property.



    Alexei,Thank you!