Set a saved or not saved flag when moving data from Excel form to worksheet
Posted on 2011-02-25
I have code that, when the user hits the Save button, move the form data into the woksheet. But I would like to have some sort of a flat that if there is data in the form and the user hits the close button, they are warned that the data has not been saved. I was thinking of a blnSaveFlag as aboolean, but am not sure where or how to initialize. When the data is aved, I can set the value to true - it would be a public variable so should be able to be recgozied by the close button, but am just a little perplexed on how to handle and where to set the value to 0.