I am always using the "Hide All Types" command when modelling but I don't like how cosmetic threads are grouped in with it. I was looking into writing a macro that would toggle on and off the visibility of whatever I have shown, leaving the cosmetic threads always shown. To do this, I need to be able to store information on what is visible or not. I'm not sure what would be the best way to do this. I've come across IGet3rdPartyStorageStore but I don't know how I would go about using it. What would be the easiest way to temporarily store information on what was toggled on and off?
SolidworksApi macros
Using third-party storage requires the Document Manager API, which I would not recommend using with models you already have open. Normally the DM API is used with stand-alones.
I would recommend you create an invisible attribute in the FeatureManager tree and store a 1 or a 0 in it depending on the current toggle state. You can learn more about attributes here. If you wanted an even simpler approach, store the 1 or 0 in a custom property.
Keith
SolidWorks API Programming