I downloaded this macro a year or so ago, and it works quite well. My only issue is that it errors if there are no configuration specific data to remove.
I've coded a bit in C, C++, Java, and Java Script, but Visual Basic baffles me. I tried to add an If statement to quit if there are no config specific data, but that didn't work as I thought it would.
What statement do I add, and where do I add it, to make this a macro I can run on anything, any number of times?
Dim swApp As Object
Dim swApp As SldWorks.SldWorks
Dim swModel As SldWorks.ModelDoc2
Dim swCustPropMgr As SldWorks.CustomPropertyManager
Dim vConfigNames As Variant
Dim vCustPropNames As Variant
Dim i As Integer
Dim j As Integer
Set swApp = Application.SldWorks
Set swModel = swApp.ActiveDoc
vConfigNames = swModel.GetConfigurationNames
'Loop through all configurations
For i = 0 To UBound(vConfigNames)
Set swCustPropMgr = swModel.Extension.CustomPropertyManager(vConfigNames(i))
vCustPropNames = swCustPropMgr.GetNames
'Loop through and delete all configuration properties
For j = 0 To UBound(vCustPropNames)