ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Save without prompts (https://www.excelbanter.com/excel-programming/322118-save-without-prompts.html)

Jeff

Save without prompts
 
I save off a backup copy of the sheet using the Auto_Close sub. However, I
always get asked to save it since a copy exists already.

ActiveWorkbook.SaveAs "h:\VBA Work\Transit Master_0.3\Transit Master_0.3.xls"

always returns the message to save. Can I save this off and avoid the
prompts like I can when I close a file

Bob Phillips[_6_]

Save without prompts
 
Precede the save code with

Application.DisplayAlerts = False

and set it back to true afterwards.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Jeff" wrote in message
...
I save off a backup copy of the sheet using the Auto_Close sub. However, I
always get asked to save it since a copy exists already.

ActiveWorkbook.SaveAs "h:\VBA Work\Transit Master_0.3\Transit

Master_0.3.xls"

always returns the message to save. Can I save this off and avoid the
prompts like I can when I close a file





All times are GMT +1. The time now is 01:52 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com