Since you seem to have a handle on my issue... I'm going to post some additional code... You might have some ideas... I do thank you for responding.
This is for an Microsoft Outlook 2016 macro. I have a boss who has asked me not to send routine emails on the weekend or off hours. My problem is I am a volunteer for this large organization and my volunteering time is second shift and weekends because I work a traditional first shift. His requirements:
A. Weekdays - do not send mail between 6PM and 8AM.
B. Weekends - do not send mail
C. Holidays - do not send mail.
I was starting off from Diane Poremsky's code at <UGH>forum is preventing me from posting the link
This does almost everything that I want, with the exception of 2 things.
(1) I am allowed to send emergency email (I respond to home fires to assist clients -- we need to send out a message stating that during no-email times. (Could I click a "Quick Button" in the toolbar that points to a macro to immediately send emergency messages?... what would that macro be?)
(2) I need to adjust the script so that I am not sending emails out on a holiday. I would be willing to edit code to allow for those dates each year.
I'm not sure how I would accomplish that. Here is the full code that I was using that got me to a good place in A. and B. above. C causes problems... and exception #1 and #2... I'm just not sure what to do.
Diane's Code:
Bookmarks