Hello There,
I have a workbook, whose functionality is, it should close the workbook without saving anychanges and without any popups to save the workbook:
In the Private Sub Workbook_Open, there are certain Call to some Sub's.
In all the Sub's related to Workbook_Open, there is the below code. It sets a global variable to True which I intend to use it in workbook_beforeclose to identify a normal close or a close by error in the subs
What code should I write in the Private Sub Workbook_BeforeClose, the workbook exit without saving or asking standard question to save?
In here, there is custom message question "Do you want to exit the application?".
When the Workbook_Open goes all okay and the User clicks on exit workbook, therefore the above custom message
Thank you for your help and look forward to hearing from you
Regards,
Don
I have a workbook, whose functionality is, it should close the workbook without saving anychanges and without any popups to save the workbook:
In the Private Sub Workbook_Open, there are certain Call to some Sub's.
In all the Sub's related to Workbook_Open, there is the below code. It sets a global variable to True which I intend to use it in workbook_beforeclose to identify a normal close or a close by error in the subs
Code:
InvalidCheck = True
Thisworkbook.close savechanges=False
What code should I write in the Private Sub Workbook_BeforeClose, the workbook exit without saving or asking standard question to save?
In here, there is custom message question "Do you want to exit the application?".
When the Workbook_Open goes all okay and the User clicks on exit workbook, therefore the above custom message
Thank you for your help and look forward to hearing from you
Regards,
Don