Hi
I have an Access database which includes code to identify e-mails in Outlook and perform various actions with them. Up to now I've used the Complete flag to identify the e-mail I wish to select:
I now wish to use the e-mail Category color e.g. yellow, to identify the email I wish to work with. I have found the olCategoryColor property but this does not appear to work in the same way as the FlagStatus property above e.g.
returns an Run-time error '438': Object doesn't support this property or method.
I'd therefore be grateful for any help or advice in the use of the olCategoryColor property.
Thanks
AL
I'd be grateful if anyone could help me with the use of olCategoryColor property
I have an Access database which includes code to identify e-mails in Outlook and perform various actions with them. Up to now I've used the Complete flag to identify the e-mail I wish to select:
Code:
Dim ns As Outlook.Namespace
Dim sent As Outlook.MAPIFolder
Dim temp As Outlook.MAPIFolder
Dim i As Integer
Dim j As Integer
Dim email As MailItem
Dim att As Attachment
Dim emailname As String
Set ns = GetNamespace("MAPI")
' Temp is a subfolder of Inbox
Set temp = ns.GetDefaultFolder(olFolderInbox)
For i = temp.Items.Count To 1 Step -1
If temp.Items(i).Class <> 43 Then GoTo nexti:
[b]If temp.Items(i).FlagStatus = olFlagComplete[/b] Then
(perform required actions)
temp.Items(i).FlagStatus = olNoFlag
(etc.)
I now wish to use the e-mail Category color e.g. yellow, to identify the email I wish to work with. I have found the olCategoryColor property but this does not appear to work in the same way as the FlagStatus property above e.g.
Code:
If temp.Items(i).CategoryColor = olCategoryColorYellow Then
returns an Run-time error '438': Object doesn't support this property or method.
I'd therefore be grateful for any help or advice in the use of the olCategoryColor property.
Thanks
AL
I'd be grateful if anyone could help me with the use of olCategoryColor property