Use the beforeclose event.
See Chip Pearson's page on events
http://www.cpearson.com/excel/events.htm
--
Regards,
Tom Ogilvy
"More Macro Help Needed"
wrote in message ...
I am looking for a way to have a file run a macro when it is being closed
(the user either hits the X or goes File Close). I want the macro to
check
certain cells and verify if there are values in them. If the cells are
blank
then I want an message box to come up saying that all cells are not filled
in
and the file remains open. Any help in this area is appreciated. Thanks
Dan