This code sends MS Project Tasks to Outlook as events.
I want to set it to a different calendar instead of my default.
The original code:
Sub Export_Selection_To_OL_Appointments()
Dim myTask As Task
Dim myItem As Object
On Error Resume Next
Set myOLApp = CreateObject("Outlook.Application")
For Each myTask In ActiveSelection.Tasks
Set myItem = myOLApp.CreateItem(1)
With myItem
.Start = myTask.Start
.End = myTask.Finish
.Subject = " Rangebank PS " & myTask.Name
.Categories = myTask.Project
.Body = myTask.Notes
.Save
End With
Next myTask
End Sub
Tried code I found online.
This demonstrates how you could reference a non-default Outlook folder to add an item.