Private Sub Workbook_BeforeClose(Cancel As Boolean)ThisWorkbook.Saved = TrueEnd SubPrivate Sub Workbook_BeforeSave(ByVal SaveAsUI As Boolean, Cancel As Boolean)ThisWorkbook.Saved = TrueCancel = TrueEnd Sub