Does anybody has an idea how to add a Task/Reminder to MS Outlook?
I found following code for MS Access but couldn't make it work in VFP. Any help greatly appreciated.
Dim appOutLook As Outlook.Application
Dim taskOutLook As Outlook.TaskItem
Set appOutLook = CreateObject("Outlook.Application")
Set taskOutLook = appOutLook.CreateItem(olTaskItem)
With taskOutLook
.Subject = "This is the subject of my task"
.Body = "This is the body of my task."
.ReminderSet = True
* Set to remind us 2 minutes from now.
.ReminderTime = DateAdd("n", 2, Now)
* Set the due date to 5 minutes from now.
.DueDate = DateAdd("n", 5, Now)
.Save
End With
I found following code for MS Access but couldn't make it work in VFP. Any help greatly appreciated.
Dim appOutLook As Outlook.Application
Dim taskOutLook As Outlook.TaskItem
Set appOutLook = CreateObject("Outlook.Application")
Set taskOutLook = appOutLook.CreateItem(olTaskItem)
With taskOutLook
.Subject = "This is the subject of my task"
.Body = "This is the body of my task."
.ReminderSet = True
* Set to remind us 2 minutes from now.
.ReminderTime = DateAdd("n", 2, Now)
* Set the due date to 5 minutes from now.
.DueDate = DateAdd("n", 5, Now)
.Save
End With