Automatically Add a Category to Accepted Meetings

Last reviewed on June 21, 2014   —  No comments yet

The idea for this macro came from Dan, who is looking for a way to assign a category when a meeting is accepted.

I would like to change the color of a meeting once the invitee accepts the invitation. Looking at my calendar if the meeting is still the default color I'd know I need to follow up to ensure they're going to attend. Do you know of a way to do this?

You can do this using a variation of our Autoaccept a Meeting Request using Rules macro, using it with a Run a Script rule to look for accepted meeting responses and then add a category to the associated appointment.

This method can be used to change any field in the associated appointment. Remember, if you change the subject, location, or time, Outlook will need to send an update.

How to use this macro

Open Outlook's VBA editor (Alt+F11), right click on Project1 and choose Insert > Module. Paste the code into the module, then create the rule with the 'run a script' Action and select this script.

Use a run a script rule to  change a meeting after it is accepted

Complete steps for using the VBA Editor and SelfCert are at How to use the VBA Editor

Sub AcceptedMeetings(oRequest As MeetingItem)
If oRequest.MessageClass <> "IPM.Schedule.Meeting.Resp.Pos" Then
  Exit Sub
End If
Dim oAppt As AppointmentItem
Set oAppt = oRequest.GetAssociatedAppointment(True)
oAppt.Categories = "Green"

End Sub

To use this macro with declined or tentative responses, change the message class to one of the following message classes:

Message ClassResponse
IPM.Schedule.Meeting.Resp.PosAccepted meeting response
IPM.Schedule.Meeting.Resp.NegDeclined meeting response
IPM.Schedule.Meeting.Resp.TentTentative meeting response

Written by

Diane Poremsky
A Microsoft Outlook Most Valuable Professional (MVP) since 1999, Diane is the author of several books, including Outlook 2013 Absolute Beginners Book. She also created video training CDs and online training classes for Microsoft Outlook. You can find her helping people online in Outlook Forums as well as in the Microsoft Answers and TechNet forums.

Please post long or more complicated questions at Outlookforums.

Leave a Reply

If the Post Coment button disappears, press your Tab key.