Retriving component id from component name

Altair Forum User
Altair Forum User
Altair Employee
edited October 2020 in Community Q&A

hi

    i need idea about retriving component id by giving component name....

   if any one know the answer,reply ..plz

Tagged:

Answers

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited August 2013

    This is a trickier process in HyperView than in HyperMesh  You need a component handle to get the component id from.

     

    You can search through the components in your model to match the name you want to the 'Label' which you can retrieve using a command such as:

     

    set compname_test [comphandle GetLabel]

     

     

    and once you know which component handle matches the one you want, you can get the ID number using

     

    comphandle GetComponentID