Thanks, Michael!! This seems like it should do exactly what I need, but it
doesn't seem to be working. I opened a blank appointment to get to the
Developer tab and then clicked Visual Basic. I added and saved the following
to ThisOutlookSession (changed category name to Personal to match my existing
category):
Private WithEvents Items As Outlook.Items
Private Sub Application_Startup()
Dim Ns As Outlook.NameSpace
Set Ns = Application.GetNamespace("MAPI")
Set Items = Ns.GetDefaultFolder(olFolderCalendar).Items
End Sub
Private Sub Items_ItemAdd(ByVal Item As Object)
If TypeOf Item Is Outlook.AppointmentItem Then
AddCategoryToPrivateAppointment Item
End If
End Sub
Private Sub AddCategoryToPrivateAppointment(Appt As Outlook.AppointmentItem)
If Appt.Sensitivity = olPrivate Then
If Len(Appt.Categories) = 0 Then
Appt.Categories = "Personal"
Appt.Save
End If
End If
End Sub
I then closed Outlook and tried adding a private appointment, but it still
doesn't have a category. The same thing happened with a private appointment
that originated on my Blackberry.
What did I mess up?
"Michael Bauer [MVP - Outlook]" wrote:
>
> Outlook has no macro recorder, but some fans who are even better...
>
> This example might work for you; it does for me with my phone and
> ActiveSync:
> http://www.vboffice.net/sample.html?...owitem&lang=en
>
> --
> Best regards
> Michael Bauer - MVP Outlook
>
> : Outlook Categories? Category Manager Is Your Tool
> : VBOffice Reporter for Data Analysis & Reporting
> : <http://www.vboffice.net/product.html?pub=6&lang=en>
>
>
> Am Wed, 23 Sep 2009 07:44:01 -0700 schrieb slapana:
>
> > Thanks! I'll give that a try, but that won't completely meet my needs.
> The
> > larger reason that I asked is because I manually sync my BlackBerry with
> > Outlook. I can mark appointments private on my BlackBerry, but can't
> assign
> > a category; I often end up with uncategorized private appointments because
> > they were originally created on my BlackBerry and I forget to update the
> > category in Outlook. I was hoping that there was a way to have Outlook
> > automatically categorize them for me, but maybe it's not an option...
> >
> > "Melissa bone" wrote:
> >
> >> Hi
> >>
> >> I'm no expert, but I recommend you try recording a macro to do this, then
> >> the macro can have a short cut and you should be able to use the shortcut
> >> whilst in your open appointment so instead of having to click the private
> >> button the shortcut makes the appointment private and allocates the
> category
> >> you previously recorded. I can't test the theory at the moment because
> the
> >> macro option is locked down at work.
> >>
> >> "slapana" wrote:
> >>
> >>> Is there a way to have Outlook 2007 automatically assign an appointment
> to a
> >>> category based on wether or not it's marked private? I use categories
> to
> >>> color code my calendar and would like to save a step by having anything
> I
> >>> mark private automatically assigned to a specific category/color.
> >>>
> >>> Thanks!
>