Checking if hole note leader points to geometry or thread symbol

Checking if hole note leader points to geometry or thread symbol

Anonymous
Not applicable
441 Views
2 Replies
Message 1 of 3

Checking if hole note leader points to geometry or thread symbol

Anonymous
Not applicable

Hello

 

I was just wondering if anyone knew how to check whether a hole note leader was attached to the geometry of the hole/thread feature or the thread symbol.

 

From there I'd be curious to know if it would be possible to automatically move it to the other, depending on which one it's on. From what little experience I have this seems like it might be pretty complex, so I'm hoping it's actually easy or there's someone out there who knows how to do it already!

 

Thanks

0 Likes
Accepted solutions (1)
442 Views
2 Replies
Replies (2)
Message 2 of 3

JelteDeJong
Mentor
Mentor
Accepted solution

Checking isn't the problem. But finding the correct curve and attaching the hole note to it seems at least very difficult if not impossible.

here is the code to check if it's attached to geometry or symbol.

Dim leader As HoleThreadNote = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kDrawingDefaultFilter, "Select a hole note")
Dim drawingCurve As DrawingCurve = leader.Edge

If drawingCurve.ProjectedCurveType = Curve2dTypeEnum.kCircleCurve2d Then
    MsgBox("Hole note is attached to geometry")
Else
    MsgBox("Hole note is attached to symbol")
End If

Jelte de Jong
Did you find this post helpful? Feel free to Like this post.
Did your question get successfully answered? Then click on the ACCEPT SOLUTION button.

EESignature


Blog: hjalte.nl - github.com

Message 3 of 3

Anonymous
Not applicable
Thanks very much!
0 Likes