cancel
Showing results for 
Search instead for 
Did you mean: 
cancel
Showing results for 
Search instead for 
Did you mean: 

Community Tip - Help us improve the PTC Community by taking this short Community Survey! X

Translate the entire conversation x

Is there a method to retrieve a string parameter value from the assigned material?

RM_5465201
2-Explorer

Is there a method to retrieve a string parameter value from the assigned material?

it seems that the function material_param() applies only for numerical parameters. You cannot access string parameters from the material with this function. Is there a method to retrieve a string parameter value from the assigned material?

2 REPLIES 2

Hi,

in Creo 10.0 I added Cast_iron_gray.mtl to test part.

Following relations work well.

x_PTC_POISSON_RATIO=material_param("PTC_POISSON_RATIO")
x_GRANTA_DATABASE_KEY=material_param("GRANTA_DATABASE_KEY")

MartinHanak_0-1727245237775.png

 


Martin Hanák

Hello RM_5465201,

Not sure if I got your question.

Notes and relationships do not make a difference for parameter type (at least, if types are not mixed). They work for all types of parameters. For sure it is not possible to treat strings as double or other way around. Creo always has issues with type conversion.

upload_-aW1hZ2UwMDEucG5n-7424487123033555079..png

upload_-aW1hZ2UwMDQucG5n-6689052116152460243..png

upload_-aW1hZ2UwMDUucG5n-4019697388715457755..png

Announcements
NEW Creo+ Topics: Real-time Collaboration

Top Tags