Announcements
Attention for Customers without Multi-Factor Authentication or Single Sign-On - OTP Verification rolls out April 2025. Read all about it here.
JaneFan
in reply to: rfink

Hey @rfink,

 

Please try setting the position with a Point2d object instead of setting the coordinates separately:

Sub Test()
    Dim oNotes As DrawingNotes
    Set oNotes = ThisApplication.ActiveDocument.ActiveSheet.DrawingNotes
    
    Dim oLeader As Object
    Dim oChamL As ChamferNote
    
    Dim oPt As Point2d
    For Each oLeader In oNotes.LeaderNotes
        Set oPt = ThisApplication.TransientGeometry.CreatePoint2d(oLeader.Position.X - 5, oLeader.Position.Y - 2)
        oLeader.Position = oPt
    Next
    For Each oChamL In oNotes.ChamferNotes
        Set oPt = ThisApplication.TransientGeometry.CreatePoint2d(oChamL.Position.X + 5, oChamL.Position.Y - 2)
        oChamL.Position = oPt
    Next
End Sub




Jane Fan
Inventor QA Engineer