My PERSONAL.xlsb has been set up for years to save before exit without the prompt to save. Now it has stopped working. It does not matter if the worksheet is opened individually or after taking the focus after closing another sheet.
In VBAProject>>ExcelObject>ThisWorkbook
I just tried putting a messagebox in the Workbook_BeforeClose event and it never fired.
In VBAProject>>ExcelObject>ThisWorkbook
VBA Code:
Private Sub Workbook_BeforeClose(Cancel As Boolean)
'Tried Private and Public
'Fails
'Workbooks("PERSONAL.xlsb").Activate
'Me.Save
'Fails
'ThisWorkbook.Saved = True
'ThisWorkbook.Save
'Fails
Application.DisplayAlerts = False
ThisWorkbook.Saved = True
ThisWorkbook.Save
Application.DisplayAlerts = True
'Created Macro in a module with the previous code.
'Fails
'Call Close_Book
I just tried putting a messagebox in the Workbook_BeforeClose event and it never fired.