Message Box before Closing file

gottimd

Well-known Member
Joined
Jul 29, 2002
Messages
501
I have a file that I send out to users on a monthly basis, and there are a few key cells that some controllers leave blank.

Is there a code that if, lets say, cell D8 is blank, that before they close the file, a message box pops up and says a brief message to them as a reminder to fill that cell in, and to make sure that they have filled in all variance explanations?

And if they press ok, it copies and pastes the name in Cell D8 from the active page, and selects a sheet in the workbook called "TitlePage", and pastes the name and current date and time (value only so it doesn't change) into Cell E47 on the title page?
 
No problem. Now I am just stuck on another problem, which I created a thread for. How to have a cell value changed automatically to 1 when opening a file.
 
Upvote 0

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
gottimd said:
Ok, works now, thanks. How do I change the Date and Time format to say the Time with AM and PM and the Month-Date and Year? I tried:

Format(Now, "h:mm", "AMPM", "MM:DD:YYYY")

Try:

[A1] = Now
[A1].NumberFormat = "mm/dd/yyyy h:mm AM/PM"
 
Upvote 0

Forum statistics

Threads
1,213,536
Messages
6,114,215
Members
448,554
Latest member
Gleisner2

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top