redspanna
Well-known Member
- Joined
- Jul 27, 2005
- Messages
- 1,604
- Office Version
- 365
- Platform
- Windows
Hi all
I want certain events to happen if the user tries to close my "records" workbook after 1800.
So if the X button is clicked or File>Close, File>Exit options are chosen and the time is after 1800 then display the "error" userform.
If the time is before 1800 then allow closure as normal.
also..on workbook open....
If the time is before 0700 and cell A1 on sheet1 is blank then show userform "error2".
If the time is after 0700 and A1 isn't blank then open as normal
NB: if call A1 isn't blank its populated with the date format yyyy-mm-dd
would really appreciate any code to help carry out the above.
many thanks in advance
I want certain events to happen if the user tries to close my "records" workbook after 1800.
So if the X button is clicked or File>Close, File>Exit options are chosen and the time is after 1800 then display the "error" userform.
If the time is before 1800 then allow closure as normal.
also..on workbook open....
If the time is before 0700 and cell A1 on sheet1 is blank then show userform "error2".
If the time is after 0700 and A1 isn't blank then open as normal
NB: if call A1 isn't blank its populated with the date format yyyy-mm-dd
would really appreciate any code to help carry out the above.
many thanks in advance