Skip to main content
Oct 2, 2023 6:53 AM UTC
Solved

Attribute of type real number

Hi community,

 

I want to get the value of an attribute in the code below. The attribute is of type real number, defined by the com.ptc.core.meta.common.FloatingPoint class. When I try to get the value it doesn't give me any results. Can you help me?

 

 

 

 

 com.ptc.core.lwc.server.PersistableAdapter obj = new com.ptc.core.lwc.server.PersistableAdapter(part,null,java.util.Locale.getDefault(),new com.ptc.core.meta.common.UpdateOperationIdentifier());
 obj.load("SURFACE_M2 ");
 SURFACE_M2 = (com.ptc.core.meta.commmon.FloatingPoint) obj.get("SURFACE_M2");

 

 

 

 

 

Oct 2, 2023 7:36 AM UTC

Hi @smcvr 

Wrong name definition >D 

obj.load("SURFACE_M2 ");

HelesicPetr_0-1696232192724.png

You added a space in the end. Remove it.

 

PetrH 

5 replies

3-Newcomer
Oct 2, 2023 7:28 AM UTC

what is the windchill version ?

smcvrAuthor
Oct 2, 2023 7:33 AM UTC

Hi @Fadel 

 

Use Windchil  12.0.2.9

Oct 2, 2023 7:36 AM UTC

Hi @smcvr 

Wrong name definition >D 

obj.load("SURFACE_M2 ");

HelesicPetr_0-1696232192724.png

You added a space in the end. Remove it.

 

PetrH 

smcvrAuthor
Oct 2, 2023 7:41 AM UTC

Hi @HelesicPetr,

 Thank you so much for your help 😄

Oct 2, 2023 7:43 AM UTC

@smcvr Four eyes see more than two 😄

PetrH