API: Activate All Configurations And Save in SolidWorks to Update the Data Stream for Document Manager

Document created by Michael Kozikowski Employee on Dec 27, 2012Last modified by Joyce Bossom on Oct 31, 2017
Version 4Show Document
  • View in full screen mode

The VBA macro looks at the folder where the macro is located and for each part or assembly there, opens the document, makes each configuration active one-by-one, rebuilds, saves, and closes the document. When the folder is parsed in full, the macro shuts down SolidWorks. This is to be used for batch processing of parts and assemblies to update the data stream that is read by the Document Manager for all part and assembly configurations. Inactive configurations could possibly not be up-to-date otherwise. Use the Document Manager API, ISwDMConfiguration10::IsDirty, to check whether it returns false to confirm that the update is successful.