Skip to main content
Jul 25, 2023 2:19 PM UTC
Solved

Windchill Atributes Type (String and Integer)

Is it possible to use an attribute connected to a CREO parameter in Windchill that reads both string and integer? If not, is there an easy way to convert the parameter type to string or integer inside the model in CREO?

 

 

 

jbaileyAnswer
Jul 26, 2023 1:32 PM UTC

That's what I figured, it would probably be easier to convert a string to integer on the Windchill side vs the relations required to first validate if the string even contains a number only... and then how to parse decimals if they exist etc.

 

3 replies

Jul 25, 2023 11:34 PM UTC

So may be more of a Creo question... You can use a relation and itos

Create a prameter type integer integ

Create a relation integ_to_str = itos(integ)

New parameter value integ_to_str is a string with the string value from the integer param

I don't know if you can convert a string to an integer in Creo

 

Jul 26, 2023 1:30 PM UTC

The only way to convert a string to an integer is a complex series of relations. It is a bit more complex than converting a floating number to a string.

jbaileyAnswer
Jul 26, 2023 1:32 PM UTC

That's what I figured, it would probably be easier to convert a string to integer on the Windchill side vs the relations required to first validate if the string even contains a number only... and then how to parse decimals if they exist etc.