Message 1 of 3
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Can anybody help?
I have the following macro. I want to list all "derived parts" in a Assembly document.
Public Function GetDerivedParts()
Dim oApp As Application
Dim oPD As AssemblyDocument
Dim oPCD As PartComponentDefinition
Dim oDerPart As DerivedPartComponent
Set oApp = ThisApplication
Set oPD = oApp.ActiveDocument
Set oPCD = oPD.ComponentDefinition
For Each oDerPart In oPCD.ReferenceComponents.DerivedPartComponents
MsgBox (oDerPart.Name)
Next
End Function
I am getting the error "13 - Type Mismatch".
Does anybody know what I am doing wrong?
Many thanks in advance!
Darren
Solved! Go to Solution.