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

@Rene_Gerlach,

 

Try the below VBA code to get referenced document from ModelLeaderNote. Will this helpful? or Looking for specific occurrence?

 

Sub Main()

    Dim oDoc As AssemblyDocument
    Set oDoc = ThisApplication.ActiveDocument
    
    Dim oDef As AssemblyComponentDefinition
    Set oDef = oDoc.ComponentDefinition
    
    Dim oNotes As ModelLeaderNote
    For Each oNotes In oDef.ModelAnnotations.ModelLeaderNotes
        Dim oReferDoc As Document
        Set oReferDoc = oNotes.Definition.Intent.Geometry.Parent.ComponentDefinition.Document
    Next
    
End Sub

Thanks and regards,

 


CHANDRA SHEKAR G
Developer Advocate
Autodesk Developer Network