There’s a nice feature in Outlook that allows users to automatically accept appointments, and even decline conflicting appointments. Unfortunately, what it can’t do is allow you to specify specific reasons for rejecting meeting invitations.

Screenshot

A particular pet hate of mine is when people send a meeting invitation entitled “Foo Discussions” or some such, and fail to specify a location or any content. It’s even more irritating when I’m trying to be a good little corporate citizen and have my calendar auto-accept appointments, but they send it ten minutes before the thing actually starts. They’re going to receive an acceptance notice (of course) but my phone’s not going to synch for a good half-hour, and there’s just no way I’m going to be there. Funnily enough, I’m not just sitting around on my backside, waiting for someone to invite me to a meeting.

Oh, a meeting! How exciting! I’ve been waiting for one of these all day!

Of course, if you simply decline offending appointments manually, people tend to get offended. (Which may or may not be a good thing, depending on who it is.) A better way, however, is to automate the process.

Nothing personal, old chap - my calendar just has automation rules that apply to everyone.

The rules for getting into my calendar are simple:

  1. Tell me everything I need to know about the meeting. This includes, specifically, its location. Outlook enforces pretty much everything else, but fails to enforce this one.

  2. Please do me the courtesy of checking my free/busy information and *do not *attempt to trump something that’s already been organised. It shows a complete and utter disregard for my time and that of anyone with whom I’ve already agreed to meet.

  3. Do me the courtesy of giving me at least 24 hours’ notice. Don’t send me a meeting request at 7pm on Monday evening for 7:30am on Tuesday morning. I’m not going to read it, and I’m not going to be there.

I finally snapped today, after another imbecilic meeting request, and wrote these two quick methods. They enforce the three rules above, automatically accept the request if it passes and automatically decline otherwise. They appear to work for me; your mileage may vary. No warranties, express or implied, etc.

Sub AutoProcessMeetingRequest(oRequest As MeetingItem)

	' bail if this isn't a meeting request
	If oRequest.MessageClass <> "IPM.Schedule.Meeting.Request" Then Exit Sub

	Dim oAppt As AppointmentItem
	Set oAppt = oRequest.GetAssociatedAppointment(True)

	Dim declinedReasons As String
	declinedReasons = ""

	If (oAppt.Location = "") Then
		declinedReasons = declinedReasons & " * No location specified." & vbCrLf
	End If

	If (HasConflicts(oAppt)) Then
		declinedReasons = declinedReasons & " * It conflicts with an existing appointment." & vbCrLf
	End If

	If (DateTime.DateDiff("h", DateTime.Now, oAppt.Start) < 24) Then
		declinedReasons = declinedReasons & " * The meeting's start time is too close to the current time. " & vbCrLf
	End If

	Dim oResponse As MeetingItem
	If (declinedReasons = "") Then
		Set oResponse = oAppt.Respond(olMeetingAccepted, True)
	Else
		Set oResponse = oAppt.Respond(olMeetingDeclined, True)
		oResponse.Body = _
			"This meeting request has been automatically declined for the following reasons:" & vbCrLf & _
			declinedReasons
	End If

	oResponse.Send
	oRequest.Delete

End Sub

Function HasConflicts(oAppt As AppointmentItem) As Boolean
	Dim oCalendarFolder As Folder
	Set oCalendarFolder = ThisOutlookSession.Session.GetDefaultFolder(olFolderCalendar)

	Dim apptItem As AppointmentItem

	For Each apptItem In oCalendarFolder.Items
		If ((apptItem.BusyStatus <> olFree) And (oAppt <> apptItem)) Then
			If (apptItem.Start < oAppt.End) Then
				' if this item starts before the given item ends, it must end before the given item starts
				If (apptItem.End > oAppt.Start) Then
					HasConflicts = True
					Exit Function
				End If
			End If
		End If
	Next

	HasConflicts = False
End Function

Just open the VBA editor from within Outlook (Alt-F11) and paste the subroutines into the ThisOutlookSession project.

Screenshot

Then go and create an Outlook rule that calls the AutoProcessMeetingRequest subroutine for every meeting request you receive:

Screenshot

Those of your colleagues who persistently refuse to learn how to use email (an essential business tool!) will receive responses along the following lines:

Screenshot