Cancel
Showing results for 
Search instead for 
Did you mean: 

How to get the position of a point pointed by a Label

Pioneer
Pioneer

Hi, I am using NXOpen C++ for my project. Here is a Label pointing to the center point of the end of a cylinder, and how can I get the position of this point? When I use .AnnotationOrigin (), it returns me the position of the label, not the point I want.

screenshot.PNG

4 REPLIES

Re: How to get the position of a point pointed by a Label

Legend
Legend

You have to get the LeaderData->Leader and use GetValue function to get the origin.

 

Look at this example on the solution center.  It is in C#.

 

https://solutions.industrysoftware.automation.siemens.com/view.php?sort=desc&q=leader+origin&dt=nx-a...

Re: How to get the position of a point pointed by a Label

Pioneer
Pioneer

But I cannot get Leader because there is no such class like LabelBuilder for me to find the leader, so how can I get Leader objects?

Re: How to get the position of a point pointed by a Label

Honored Contributor
Honored Contributor

A DraftingNoteBuilder object will give you access to the leader data.

Re: How to get the position of a point pointed by a Label

Pioneer
Pioneer
I get it, thank you very much!!!