close workbooks

New Contributor

when i close an excel-workbook there doesn't come the Question: "Do you want to save?" Can i activate this?



7 Replies


You should only get the prompt if the workbook has been modified, of course.

Are you using Excel Online? It saves workbooks automatically.


If you are on Windows or MacOS: could you have run a macro that disables events? If so:

Press Alt+F11 to activate the Visual Basic Editor.

Press Ctrl+G to activate the Immediate window.



Application.EnableEvents = True


and press Enter.

Switch back to Excel.

@Hans Vogelaar 

Thank you, but it doesn't work.


I work with a notebook, windows 10 and Microsoft 365. I save local.


If I make a new workbook, save it - then comes the question.

But if i open it again, change something and close, then doesn't come the question and the change is lost.



That is strange. See if Tina Chen's reply in Excel not asking if I want to save changes helps.

best response confirmed by Aweham (New Contributor)
Could you have some vba code that disables alerts? Using the same instructions as Hans gave you, open the immediate window and see what the current setting is:


And you can try turning it back on with:
Application.DisplayAlerts = True
Sorry. I clicked wrong. It doesn't work.
?Application.DisplayAlerts says true!
Thank you. Nice Advice, but doesn't solve my problem.
I will phone with microsoft.


Personally, the only things I know that affect that behavior is the Application.DisplayAlerts property and the workbook's saved property (when you make changes, the saved property is set to false and excel will ask if you want to save changes upon exit; after saving, it is set to true).

You could enter this in the immediate window and check the saved property:
to see if excel is changing it as expected. But, if Excel's not changing it as it should automatically, then the only thing I could suggest would be to try re-installing office (which you might consider trying regardless).