ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   When Wanting To Replace Previously Saved .xls File (https://www.excelbanter.com/excel-programming/316400-when-wanting-replace-previously-saved-xls-file.html)

Chuckles123[_47_]

When Wanting To Replace Previously Saved .xls File
 

Is there any way to do this in VBA code so that the user is not prompte
with the 'Replace?' Question?

Thanks for a response,
Chuckles12

--
Chuckles12
-----------------------------------------------------------------------
Chuckles123's Profile: http://www.excelforum.com/member.php...fo&userid=1494
View this thread: http://www.excelforum.com/showthread.php?threadid=27725


Stephen Bullen[_4_]

When Wanting To Replace Previously Saved .xls File
 
Hi Chuckles123,

Is there any way to do this in VBA code so that the user is not prompted
with the 'Replace?' Question?


Yes, put:

Application.DisplayAlerts = False

before the Save As, and

Application.DisplayAlerts = True

after it.

Regards

Stephen Bullen
Microsoft MVP - Excel
www.oaltd.co.uk




All times are GMT +1. The time now is 06:17 AM.

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