CE Update 13 VBA - FindItemTypeLibraryFromDesignFileAndDgnLibs

I have not been able to get the code snippet out of the help examples (copied below) to return any value. I am trying to get the ItemTypeLibribry from my dgnlib without having one in my dgn.

Has anyone been able to get this work or is this a bug?  I put '*' instead of '*a*' to try and get any it can find, but that didn't help either.

Sub FindItemTypeLibraryFromDesignFileAndDgnLibs()

    Dim oItemLibs As ItemTypeLibraries
    Dim oItemLib As ItemTypeLibrary
    Dim oDgn As designFile
    Dim oAtt As Attachment
    
    For Each oAtt In ActiveModelReference.Attachments
        Set oDgn = oAtt.designFile
        Set oItemLibs = New ItemTypeLibraries
        Do
            Set oItemLib = oItemLibs.FindForDesignFile("*a*", oDgn, True, oItemLib)
            If oItemLib Is Nothing Then Exit Do
            Debug.Print oItemLib.LibName
        Loop
    Next

End Sub

Parents Reply Children