I can use the IModelDoc2.IGet3rdPartyStorage (in tandem with IRelease3rdPartyStorage) to write custom data into the SolidWorks file.
But how do I remove it?
I could not find any deletion method in the API docs.
Looks like the only way to do this is using Document Manager API: 2017 SOLIDWORKS API Help - Delete3rdPartyStorage Method (ISwDMDocument20)
Just write an empty string to it. That should do the trick.
unfortunately, no. If the 3rd party storage for a certain name has never been written to, the IGet3rdPartyStorage call will return null instead of an IStream. But if I write an empty string, IGet3rdPartyStorage will NOT return null. I am looking for a way to revert back to the state where nothing has ever been written to the store.
Retrieving data ...