Fetching user-defined fields from Outlook

M

Marcus Langell

Hi!
I am fetching tasks from Outlook and it works well for the Outlook-defined
columns like Subject, DueDate etc. but I don't know how to get my
user-defined columns. Any ideas? Se example below

/Marcus

Set olApp = New Outlook.Application
Set olNamespace = olApp.GetNamespace("MAPI")
Set olFolder = olNamespace.GetDefaultFolder(olFolderTasks)
Set olColItems = olFolder.Items

For Each olItem In olColItems
If TypeName(olItem) = "TaskItem" Then
With olItem
Cells(i, 1).Value = .Subject
Cells(i, 2).Value = .Categories
Cells(i, 3).Value = .StartDate
Cells(i, 4).Value = .Prio 'this does not work since it's not
recognized

Next olItem
End If
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top