Hypermesh Customization problem about hm_getvalue

shiucomp5
shiucomp5 Altair Community Member
edited December 2023 in Community Q&A

I know the ID of a set, so I use the following program to get the name of the set.

hm_getvalue sets id=4 dataname=solvername
image
My question is, if I want to do the reverse, when I know the name of a set, how can I query the ID of that set?"

i am new user for hypermesh customization.

I'd like to ask for guidance from experts. Can you please provide some advice?

Tagged:

Answers

  • Fred_Juras
    Fred_Juras
    Altair Employee
    edited December 2023

    Hi,

    Using the hm_getvalue command, there are several ways to provide the entities to be queried; for instance by id or by name. More details here: https://help.altair.com/hwdesktop/hwd/topics/reference/hm/hm_getvalue.htm

    Thus, if you know the name and want to query the id of a set, you can still use the hm_getvalue command, like this:

    hm_getvalue sets name=const1_set dataname=id

     

    Regards,
    Fred.

  • shiucomp5
    shiucomp5 Altair Community Member
    edited December 2023

    Hi,

    Using the hm_getvalue command, there are several ways to provide the entities to be queried; for instance by id or by name. More details here: https://help.altair.com/hwdesktop/hwd/topics/reference/hm/hm_getvalue.htm

    Thus, if you know the name and want to query the id of a set, you can still use the hm_getvalue command, like this:

    hm_getvalue sets name=const1_set dataname=id

     

    Regards,
    Fred.

    exactly, i try before,but fail.

    image

  • Fred_Juras
    Fred_Juras
    Altair Employee
    edited December 2023

    Is your set named const1_set or constl_set? In other words, is it the number 1 or the letter L?

    If neither works, could you try to remane the set in the GUI (for instance 'hello') and re-execute the command: hm_getvalue sets name=hello dataname=id.
    Does it work now?

    Regards,
    Fred.