audit and qsave macro

audit and qsave macro

demus72
Collaborator Collaborator
1,111 Views
8 Replies
Message 1 of 9

audit and qsave macro

demus72
Collaborator
Collaborator

I select qsave from a toolbar in my AutoCad environment. I find myself running audit more often all the time so I thought I would add audit to the qsave macro on my toolbar, ^C^C_AUDIT;Y;QSAVE;.

 

It works fine but what's strange is when I decide to close a drawing after executing this macro from my toolbar, I'm prompted with the popup asking if I want to save the drawing.

Autocad Save changes.jpg

It's as if the qsave in my macro executed from my toolbar isn't recognized? If it is working correctly, why am I receiving this prompt to save because I thought I just did?

 

Thanks

0 Likes
1,112 Views
8 Replies
Replies (8)
Message 2 of 9

pendean
Community Legend
Community Legend
@Anonymous Before you posted over here, did you expand your commandline (CTRL+F2) to see if your QSAVE happened at all? What did you discover?
I assume there is not a period after the word QSAVE in your macro, you just like to fully end sentence as you time here, yes?

FWIW... If you run the macro then close the file right away, that pop-up should never show up.
But if you zoom/pan, switch tabs or do much of anything else in the file after running the macro, AutoCAD will always prompt you to save.

Are you perhaps doing the latter, not the former? Your C3D is registering a change.
0 Likes
Message 3 of 9

demus72
Collaborator
Collaborator

Thanks for the reply pendean.

 

I did investigate the qsave and I verified my drawing is being saved by checking the date/time of my dwg file in the project folder of windows explorer with the view set to details.

 

And no, there is no period (.) at the end of my macro. I try to use proper punctuation at all times.....even here on the forums. 😅

 

I agree with you pendean, as long as I close my drawing immediately without any additional user input, I shouldn't receive the prompt to save.

0 Likes
Message 4 of 9

demus72
Collaborator
Collaborator

Why would this macro:

 

^C^C_AUDIT;Y;QSAVE; 

 

prompt me to save when I go to close my drawing immediately after being ran?

 

Any suggestions are greatly appreciated.

 

Thanks

0 Likes
Message 5 of 9

pendean
Community Legend
Community Legend
@Anonymous closing an open DWG file right after I run your macro in a button on the QAT does not present that prompt/alert and works 100% of the time for me in my files in AutoCAD 2023.1.2 (not C3D) in a test here.
0 Likes
Message 6 of 9

dmfrazier
Advisor
Advisor

See if modifying the macro by adding a "." (period) to the front of the QSave command makes any difference:

^C^C_AUDIT;Y;.QSAVE;

You can also try a "-" (dash) instead.

0 Likes
Message 7 of 9

demus72
Collaborator
Collaborator

pendean, thank you for taking the time and verifying it works on your end. I don't know why it doesn't run cleanly for me? In fact, when I added the audit, I added it to the otb qsave toolbar button. I thought maybe this was the issue and so I created a new command from scratch for my toolbar, unfortunately, this returns the same result.

 

Thanks for the tip dmfrazier, I tried both the "." and the "-". I received the same prompt to save after it was ran with the "." and AutoCad told me "Unknown command" with the "-". I also tried an underscore "_" and the qsave ran but I was prompted to save when attempting to immediately close.

 

Guess I'll have to go back to running my audit and qsave separately, but it was worth a try right?

 

I appreciate the responses from both of you.

0 Likes
Message 8 of 9

dmfrazier
Advisor
Advisor

Maybe we're looking in the wrong place.

One more (last?) thing to try is to run CLOSE with the dot or underscore.

0 Likes
Message 9 of 9

pendean
Community Legend
Community Legend

@demus72 wrote:

pendean, thank you for taking the time and verifying it works on your end.


pendean_0-1676920997498.png

 

pendean_0-1676921161994.png

 

0 Likes