How to extract name of the input file *.IGS to name the associated component

ve3D
ve3D Altair Community Member
edited October 2020 in Community Q&A

Hi,

I’am trying to extract name of the input file for exmple 'NIV7_M0300.igs' to name the associated component by 'NIV7_M0300' :

 

*geomimport 'iges_altair' 'D:/PROJET/IGSforHPM/NIV7_M0300.igs' 'CleanupTol=-0.01' 'DoNotMergeEdges=off' 'ImportBlanked=off' 'ScaleFactor=1.0'

 

The problem is that when I import a file .igs in hypermesh, it will generate an arbitrary name of the component 'lvl53'. So I can not get the name  'lvl53' generated by hypermesh to change it to NIV7_M0300:

 

{Renamed Components from 'lvl53' to 'NIV7_D0300'}

*setvalue comps id=3 name=NIV7_D0300

 

Could anyone help me please?

 

Thanks for your helps

 

Best regards

Tagged:

Welcome!

It looks like you're new here. Sign in or register to get started.

Answers

  • tinh
    tinh Altair Community Member
    edited April 2018

    Hi

    try using hm_latestentityid comps to retrieve new created coms id and rename it

  • ve3D
    ve3D Altair Community Member
    edited April 2018

    Hi Tinh,

    Thank you very much for your fast response.

    I'm a beginner in HyperMesh. If I understand, the code is:

    *setvalue comps id=hm_latestentityid  name=NIV7_D0300

     

    Best regards

  • tinh
    tinh Altair Community Member
    edited April 2018

    Hi Tinh,

    Thank you very much for your fast response.

    I'm a beginner in HyperMesh. If I understand, the code is:

    *setvalue comps id=[hm_latestentityid comps] name=NIV7_D0300

     

    Best regards

     

  • ve3D
    ve3D Altair Community Member
    edited April 2018

    Hi Tinh,

    Thanks very much for your helps.

    It works perfectly

    Best regards

Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.