We've an input sheet with macros that validate the inputs before user saves the document.
To make macros mandatory, i have included events during open and close of the workbook-standard method i guess.
These are the lines in the 'workbook before close' event.
This will hide all the sheets except "Enable Macros" so that the next time user opens the doc, evey other sheet will be hidden unless he enables macros (which triggers another event making the other sheets visible)
But the problem is that, excel generates a challenge box "do you want to save changes?" because the above lines involve hiding sheets. If user clicks No, there would be no use in the above event.
So i would like to find a way to save only this 'hiding the sheets part' when the user tries to close the doc even if he clicks "No" in the above challenge box. If Yes is clicked, all changes are to be saved including the hiding part.
The actual requirement is that, irrespective of whether or not user wishes to save the changes he has done after the last save, system should save the "hiding the sheets" part.
Any ideas?
Bookmarks