Answering "Yes" When Saving Over a File

Ste_Moore01

Active Member
Joined
Jul 13, 2005
Messages
467
Hi everyone,

I've created a macro that does various things on my sheet. At one point, it saves the sheet over an existing file but when it gets to that point it asks me if I want to save over the existing file. Is there some code I can put in my macro which would automatically answer this as yes?

Thanks!
 

Excel Facts

Format cells as currency
Select range and press Ctrl+Shift+4 to format cells as currency. (Shift 4 is the $ sign).
Hi, Ste_Moore01 !
just use
Code:
Application.DisplayAlerts = False
'code
Application.DisplayAlerts = True

kind regards,
Erik
 
Upvote 0

Forum statistics

Threads
1,203,027
Messages
6,053,120
Members
444,640
Latest member
Dramonzo

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top