Skip to main content
1-Visitor
October 24, 2019
Solved

Material ID

  • October 24, 2019
  • 2 replies
  • 7619 views

Hello,

 

I am having trouble finding the material ID for use in a note.  I have created a new parameter in my material called "SPEC" that I'd like to use in my note.  But I cannot find where to get the MTRL_ID

 

Thanks for any assistance.

Best answer by Roy_Crerar

Hi, Here is the way I do it.

If your user defined parameter in material is called SPEC then to reuse that as a note the I pull the material parameter into a model parameter. It might work by just doing &material_param("SPEC") but I would create the relation to make SPECIFICATION=material_param("SPEC") then the note is &SPECIFICATION. As it happens I also have IF else statements to show the note as unassigned if the material has not been assigned to the part.

2 replies

kdirth
21-Topaz I
October 24, 2019

Is your material ID in the parameter list?  If it is copy the exact name of the parameter.  In your annotation type "&" then the parameter name. (e.g. &MTRL_ID).

There is always more to learn.
1-Visitor
October 29, 2019

Hi, Here is the way I do it.

If your user defined parameter in material is called SPEC then to reuse that as a note the I pull the material parameter into a model parameter. It might work by just doing &material_param("SPEC") but I would create the relation to make SPECIFICATION=material_param("SPEC") then the note is &SPECIFICATION. As it happens I also have IF else statements to show the note as unassigned if the material has not been assigned to the part.

23-Emerald III
October 29, 2019

Segment from one of my material files:

{
Name = PDM_NAME
Type = String
Default = 'A36 STEEL'
Access = Full
},
{
Name = DESCRIPTION1_U
Type = String
Default = 'UNS K02599, STEEL'
Access = Full
},
{
Name = DESCRIPTION2_U
Type = String
Default = 'A36 STEEL'
Access = Full
},
{
Name = DESCRIPTION3_U
Type = String
Default = 'A36 ST'
Access = Full
},

 

Segment from my Relations:

/*** SET MATERIAL PROPERTIES ***
IF PTC_MATERIAL_NAME=="UNASSIGNED"
MATERIAL="UNASSIGNED"
MATERIAL_DESC1="NO MATERIAL ASSIGNED"
MATERIAL_DESC2=""
MATERIAL_DESC3=""
ELSE
MATERIAL=material_param("PDM_NAME")
MATERIAL_DESC1=material_param("DESCRIPTION1_U")
MATERIAL_DESC2=material_param("DESCRIPTION2_U")
MATERIAL_DESC3=material_param("DESCRIPTION3_U")
ENDIF

 

Once a material is set, the relations pull the parameter information in.

 

In the model file, we have a saved annotation (material_std_note):

&MATERIAL_DESC1
&MATERIAL_DESC2
&MATERIAL_DESC3

 

This gets pulled into the drawing.

1-Visitor
October 29, 2019

Why are there 3 different material descriptions?