Skip to main content
15-Moonstone
August 19, 2014
Solved

material ID

  • August 19, 2014
  • 1 reply
  • 1540 views

I have scoured the creo help for information regarding material ID, and yet I'm still missing something..

 

for example if I would like to drive geometry of any given part from an assigned material parameter....

 

WIDTH=FLANGE_WIDTH:MTRL_99

 

The "99" I understand to be the material ID.

 

When used in an IF statement..

 

 

IF PTC_MATERIAL_NAME=="C15X50"

WIDTH=FLANGE_WIDTH:MTRL_99

ENDIF

 

now after assigning it a different material, then reverting back to the original material, "C15X50".

 

 

I get this......

 

IF PTC_MATERIAL_NAME=="C15X50"

DEPTH=C_DEPTH:MTRL_99

error Invalid symbol 'C_DEPTH:MTRL_99' found.

ENDIF

 

 

So why would the ID have changed?


This thread is inactive and closed by the PTC Community Management Team. If you would like to provide a reply and re-open this thread, please notify the moderator and reference the thread. You may also use "Start a topic" button to ask a new question. Please be sure to include what version of the PTC product you are using so another community member knowledgeable about your version may be able to assist.
Best answer by DHLewis

Joe,

The ID has changed because you have changed the assigned material. So that if the new material had different parameters it would know the difference. It has been noted that if you use this context, you can refer to the current active material.

Your relation for Material Description would be:

MATERIAL=material_param("PTC_MATERIAL_DESCRIPTION")

So in your Flange Width Example it would equivalently be:

WIDTH=material_param("FLANGE_WIDTH") to get the width for whatever material is currently assigned.

1 reply

DHLewis13-AquamarineAnswer
13-Aquamarine
August 19, 2014

Joe,

The ID has changed because you have changed the assigned material. So that if the new material had different parameters it would know the difference. It has been noted that if you use this context, you can refer to the current active material.

Your relation for Material Description would be:

MATERIAL=material_param("PTC_MATERIAL_DESCRIPTION")

So in your Flange Width Example it would equivalently be:

WIDTH=material_param("FLANGE_WIDTH") to get the width for whatever material is currently assigned.