I would like to do a macro to turn on and shut off addins in my solidworks. Anybody have any ideas.
- posted
18 years ago
I would like to do a macro to turn on and shut off addins in my solidworks. Anybody have any ideas.
How would this be any simpler than going to "Tools --> Addins"?
Um.. use the Solidwroks office toolbar?
unless your referring to other addins that are on the office toolbar.
Hope that helps SteveT.
How about this one... Got it from NG bout two years back... cant remember from who....
Just modify the path to your add-in DLL... works fine here.
---------------------------------
Dim swApp As Object
Dim RetVal As Long
'Path to the add in DLL for your application Const strAddInPath As String = "C:\the_path_to_your_addin"
Sub main()
Set swApp = Application.SldWorks If Not swApp Is Nothing Then RetVal = swApp.LoadAddIn(strAddInPath) 'Load Add in If RetVal = 2 Then 'add in already loaded 'Unload the add in swApp.UnloadAddIn strAddInPath End If End If Set swApp = Application.SldWorks End Sub
PolyTech Forum website is not affiliated with any of the manufacturers or service providers discussed here. All logos and trade names are the property of their respective owners.