• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 63
  • Last Modified:

Outlook appointment: way (script?) to change the "Category" field based on the "Show As" field

Hi Experts

I like to use Categories to change the colour of certain Outlook appointments. I usually do this when I create the appointment.

I have a 3rd party app that creates appointments in my calendar. I cannot ask the 3rd party app to set a particular Category - BUT - I can ask it to set the "Show As" field (Free, Tentative, Busy, Out of the Office)

Is there a way to change an Appointment Category after it is created based on its "Show As" value? I assume this needs to be scheduled every xx (15) minutes??

Alexandre Michel
Alexandre Michel
  • 4
1 Solution
yo_beeDirector of Information TechnologyCommented:
Do you want this to change whenever the Show As changes.
So if Tentative it is Yellow, but when it changes to busy be Red or upon creation it is set then and never will change unless human intervention is involved?
Alexandre MichelManager; IT ConsultantAuthor Commented:
Yes, I would like indeed to have
Free = Green,
Tentative = Category Yellow
Busy = Category Orange and
Out f the Office = Category Red

The "Show As" is generally changed by the 3rd party app.

I assume that there could be a script that could run every so often and check the "Show As" for  all appointments, then change the "Category" accordingly.
Alexandre MichelManager; IT ConsultantAuthor Commented:
I am doing some research and found a script that could be modified
It comes from http://www.slipstick.com/outlook/calendar/automatically-change-appointment-categories-vba/ 

Public Sub AddCategory()
 Dim Appt As Object

  Set Items = Session.GetDefaultFolder(olFolderCalendar).Items
   For Each Appt In Items
    On Error Resume Next

If Appt.End < Now() Then
    With Appt
       .Categories = "Completed"
       .ReminderSet = False
    End with
End If
Set Appt = Nothing

End Sub

Open in new window

I now need to find a way to replace Appt.End < Now() with something that test the value of "Show As"
Alexandre MichelManager; IT ConsultantAuthor Commented:
Update & Resolution:

I found a way to do this without using VBS... Instead, I can use Conditional Formatting
Here are some links explaining the way to do it
Alexandre MichelManager; IT ConsultantAuthor Commented:
This solves the issue in a much easier way that using a script and it is instantaneous
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

We Need Your Input!

WatchGuard is currently running a beta program for our new macOS Host Sensor for our Threat Detection and Response service. We're looking for more macOS users to help provide insight and feedback to help us make the product even better. Please sign up for our beta program today!

  • 4
Tackle projects and never again get stuck behind a technical roadblock.
Join Now