I am attempting to have a macro look through features in any part, identify all reference curves, and identify the file path that defines that curve.
I've got the macro identifying reference curves just fine, the part I do not know how to do is identify the corresponding file path. What's the best way to do that? I've included what I have so far below.
Thanks in advance for any help.
Sub curveCheck()
Dim swApp As SldWorks.SldWorks
Dim swModel As SldWorks.ModelDoc2
Dim swFeat As SldWorks.Feature
Dim swSelectionManager As SldWorks.SelectionMgr
Set swApp = Application.SldWorks
Set swModel = swApp.ActiveDoc
Set swSelectionManager = swModel.SelectionManager
Do While Not swFeat Is Nothing
If swFeat.GetTypeName2 = "CurveInFile" Then
Set swFeat = swSelectionManager.GetSelectedObject6(1, -1)
'This is the part where I'm lost and would like to fill in the path.
End If
Set swFeat = swFeat.GetNextFeature
Loop
End Sub
SolidworksApi macros