44 Replies Latest reply on Apr 12, 2018 8:40 AM by Michael Abi-Kheirs

    Macro for saving solidworks drawing as a .dwg file

    Randy Franklin

      I am reposting something that I never got an answer on in hopes somebody will see this and can help.  I create solidworks sheetmetal drawings with an extra 1:1 scale flat pattern view placed just above the drawing sheet for our programmers to create a cutting program from.  I am looking for a macro that will just save the drawing with the same file name as a .dwg file in the same location as the solidworks drawing.  It has to be saved at the 1:1 scale as mentioned above.  I do not want to use the task scheduler, I want a macro.  It would be nice if the macro closed the solidworks drawing after performing this action.  I have used the macro recorder to record doing this and it works good.  The only problem is that it records the specific drawing name and file location used to make the recording and applies that to the next drawing that I use it on instead of the next drawing's file name and file location.  I am just learning a little about API and do not know how to write one myself.  I am sure somebody that knows what they are doing could go in and edit the macro recording and make it work like I want.  Please help, this would save me alot of mouse clicks, especially when I have more than 1 drawing to save.