I would like my assembly to do an auto rebuild (Ctl+Q) when I open the file. Is there a way to do this?
Under Tools>Options>Performance, there is an option to rebuild assembly on load - see below.
I believe that does a Ctl+B and not a Ctl+Q. I need the Ctl+Q
Maybe use a macro?
Running a macro on startup hides the SolidWorks splashscreen
I need the rebuild to happen no matter who opens the file in our engineering group (40+ people).
I see...I'm not really a macro guy. Josh, is there a way to do this with a macro?
I know I saw something called a macro feature that can be added to the feature tree. I believe Artem either helped someone with them or put something together with them. Would this be possible with a macro feature?
Wayne Schafer wrote: I believe that does a Ctl+B and not a Ctl+Q. I need the Ctl+Q
Wayne Schafer wrote:
Like others said, it can be done via a macro which can be made to keep running in background and automatically run on opening of assembly file.
How do you add Macro as Macro Feature?
Just an idea.There should be a macro in the public folder instead of a drawing file.all users should open that drawing with a macro.The macro must first open the drawing, then make Ctrl Q.
SOLIDWORKS Utilities - Macro Feature inside the Feature Manager - May 2016 - YouTube
Is it possible to add a Ctl+Q to the macro below. I would need help on how to do that.
Wayne Schafer wrote: Is it possible to add a Ctl+Q to the macro below. I would need help on how to do that.
I have made the change you suggested and run the macro while the assembly file is being opened but it does not do the Clt+Q.
Wayne Schafer wrote: I have made the change you suggested and run the macro while the assembly file is being opened but it does not do the Clt+Q.
The macro won't run on it's own. You will have to run that other macro and then this macro would run.
I run this macro and it adds the show comments macro where I attach the Show Comments.swp
Wayne Schafer wrote: I run this macro and it adds the show comments macro where I attach the Show Comments.swp
Maybe if you type Control-Q it'll run the macro feature...
Kidding aside, did you enable the option to rebuild upon opening a file as posted above?
Do Clt+Q or force rebuild and macro would work as expected. I've tested it and it works fine.
Thanks Deepak, I know doing the Clt+Q after the file is open and the comments show. I was hoping that when someone opens the file the Clt+Q would happen during the open process and show the comments.
You need to use this macro Run VBA macro automatically on document load using SOLIDWORKS API by Artem Taturevych
You can set the macro to run the show comments macro which has the force rebuild and show comments both. You need to change following module and add runmacro2 method to run show comments macro or have the codes pasted in the following module.
Retrieving data ...