M
mcolson
I would like to have an event that runs when a workbook is closed if
the save button is pressed. I was trying to run the macro with a
Workbook_BeforeClose event, but this wasn't working for me. If the
user hits cancel, the macro still runs. I would be fine with that if
I could easily reverse the action because the cancel button was
pressed. Does anyone have any suggestions. Basicially, the macro
should run when actually closing the workbook. If cancel is pressed,
it should not run. I tried using the workbook deactivate event, but
the macro was running if I switched to another workbook.
the save button is pressed. I was trying to run the macro with a
Workbook_BeforeClose event, but this wasn't working for me. If the
user hits cancel, the macro still runs. I would be fine with that if
I could easily reverse the action because the cancel button was
pressed. Does anyone have any suggestions. Basicially, the macro
should run when actually closing the workbook. If cancel is pressed,
it should not run. I tried using the workbook deactivate event, but
the macro was running if I switched to another workbook.