US$0.00
0

SOLIDWORKS Macro for Automated Batch Export of Configurations to STEP

Description

The SOLIDWORKS macro provided here is a means to batch export configurations to STEP.

System Requirements

  • SolidWorks Version: SolidWorks 2014 or newer
  • Operating System: Windows 7 or later

Pre-requisites

  • You should have an assembly or part document with at least one configuration open.
  • The macro should be run in the SolidWorks environment.

Results

  • All configurations in the active document are saved as separate STEP files, ensuring that each design iteration is isolated from one another.
  • The user determines the file name and destination by providing a unique file prefix and output directory.
  • When the batch export process proceeds, status and progress are tracked via a progress bar.

Steps to Set Up the Macro

  1. Opening The SOLIDWORKS Document
  • Prior to executing the following instructions, ensure that the Assembly or Part file containing the design configurations you wish to export is the active document in SOLIDWORKS.
  1. Executing the Macro
  • Opening the VBA Editor: A VBA editor can be opened while SOLIDWORKS is open by pressing Alt + F11.
  • Loading the Code: Add a new module using Insert > Module and paste the provided VBA code from the SOLIDWORKS macro for automated batch export in the new module window.
  • Executing: You can either run the macro in the VBA Editor by selecting  Run > Run Sub/UserForm, or you can save the macro as a macro file (.swp), then it can be run from the SOLIDWORKS menu (Tools > Macro > Run).
  1. Specify Output Parameters

After the macro has been run, you will then be prompted to input two critical parameters:

  • File Prefix: Input a static string (e.g., “Project_Model_”) that will be added to the beginning of each exported file name, and help in identifying related files.
  • Output Directory: Input the name of a new folder (e.g., “STEP_Exports”) that the exported files will go into.

Verify Completion

Confirm the outcome of the process:

  1. The progress bar will display progress in real-time, showing each configuration’s status as it is processed and saved.
  2. Once all configurations have been successfully converted, one last message box will appear, listing the total number of new STEP files that were saved to the path you provided.

VBA Macro Code

Macro

You can download the macro from here

Our team of experts is at your service!

Contact us today to develop a custom solution that meets your specific workflow needs!

Author

Amen Jlili

Amen Jlili is the founder and technical director of Blue Byte Systems Inc., a software company in Vancouver, Canada, specializing in automating SOLIDWORKS and PDM. With over a decade of experience, he has authored several courses and open-source frameworks related to the SOLIDWORKS API. His leadership ensures that Blue Byte Systems prioritizes customer satisfaction and delivers high-quality software and CAD design solutions.
0
    0
    Your Cart
    Your cart is emptyReturn to Shop
    ×