Hi @Ralf_Krieg
Something like this maybe? 🙂
Sub Main
'Get a nativeobject for an edge, I dont know where you're getting the edge object from.
Dim oEdge As Edge = ThisApplication.CommandManager.Pick(SelectionFilterEnum.kPartEdgeFilter, "Pick edge.").NativeObject
Dim oPart As PartDocument = oEdge.Parent.ComponentDefinition.Document
Dim oAsm As AssemblyDocument = ThisDoc.Document
Dim oSelSet As SelectSet = oAsm.SelectSet
Dim oEdgeCol As ObjectCollection = ThisApplication.TransientObjects.CreateObjectCollection
For Each oOcc As ComponentOccurrence In oAsm.ComponentDefinition.Occurrences.AllReferencedOccurrences(oPart)
Dim oEdgeProx As EdgeProxy = CreateEdgeProxy(oOcc.OccurrencePath, oEdge)
oEdgeCol.Add(oEdgeProx)
Next
oSelSet.SelectMultiple(oEdgeCol)
End Sub
Function CreateEdgeProxy(oOccList As ComponentOccurrencesEnumerator, oEdge As Edge) As Object
Dim oProx As Object
For i = oOccList.Count To 1 Step -1
If i = oOccList.Count
Call oOccList(i).CreateGeometryProxy(oEdge, oProx)
Else
Call oOccList(i).CreateGeometryProxy(oProx, oProx)
End If
Next
Return oProx
End Function