2 Replies Latest reply on Jul 15, 2016 9:11 AM by Brandon Jacobi

    Macro Visual Basic Editing

    Brandon Jacobi

      I have recorded a macro to set all file locations to a central location. The design library has several line entries. When running the macro only the last line is set in the file locations. How can I add all design library locations? How can I modify the code?

       

      boolstatus = swApp.SetUserPreferenceStringValue(swUserPreferenceStringValue_e.swFileLocationsDesignLibrary, "C:\DSC-PDM\Support\SolidWorksSystemOptions\Design Library")

      boolstatus = swApp.SetUserPreferenceStringValue(swUserPreferenceStringValue_e.swFileLocationsDesignLibrary, "C:\DSC-PDM\Support\SolidWorksSystemOptions\Blocks")

      boolstatus = swApp.SetUserPreferenceStringValue(swUserPreferenceStringValue_e.swFileLocationsDesignLibrary, "C:\DSC-PDM\Library\Aerospace")

      'boolstatus = swApp.SetUserPreferenceStringValue(swUserPreferenceStringValue_e.swFileLocationsDesignLibrary, "C:\DSC-PDM\Library\CTechnology")

      'boolstatus = swApp.SetUserPreferenceStringValue(swUserPreferenceStringValue_e.swFileLocationsDesignLibrary, "C:\DSC-PDM\Library\EEffectors")