Material ID
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Material ID
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.
Solved! Go to Solution.
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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 in Creo.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
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.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Why are there 3 different material descriptions?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
This is a bad example because A36 is a common material. We use some materials that need the 3 lines for their descriptions to get fully defined. If a description line is blank, it will be blank on the drawing.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Is it possible to put a parameter table in the .mtl? I notice the syntax the beginning of the file is different from the restricted value parameter files.
ND_RelParSet_K01 = { ***from .mtl first line
ND_ParamDefArr_K01 = { ***from restricted value file first line
and the parameter table line is
ND_ParamTable_K01 = {
Wondering if a table in the .mtl file needs to be something like "ND_RelParTable_K01"?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I was having trouble defining the material's ID in the part file itself. But eventually found that I didn't need the ID to call it. That the &material_param("xxxx") method called the active material.
Thanks you for your reply!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Material ID could be found by adding a material parameter to relationships.
Creo will prompt a list with all available material
select material by name
Creo replaces it with internal ID
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Can you please provide syntax/example to it for understanding it better.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Log into Creo and go to File-Prepare and then select assign material. You can create a blank material file that will give you the syntax for the material files. In the other thread, I pasted a full file for 7075-T6.
The Creo online help has a section on the Material Library.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You could start from drawing relationships as well as from model relationships.
Material-ID number could be copy-paste to be used on any note.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I tried this method
1. Write material= in relations
2. Go to parameter
3. Select PTC_MASTER_MATERIAL
The relation is successfully added but the material ID is not displayed. Can you please let me know where the material ID will be displayed?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi,
For me it shows up on pos 6 (see attached screenshot). E.g. I added the IACS electrical value.
I didn’t try with PTC standard material. Works perfect for materials assigned by me.
Our Standard parts always have materials assigned so I am not able to check out of the box behavior.
Did you follow the steps on drawing?
Go to relationships Add new variable Add parameter > search in “material” > select your material from list > add attribute parameter from available parameter list. After “add selected” and close parameter selection window, MTL ID should show up in relations editor line.