Adding Task to Outlook

G

gumby

Option Compare Database
Option Explicit

Function AddOutLookTask()
Dim OutlookApp As Outlook.Application
Dim OutlookTask As Outlook.TaskItem
Set OutlookApp = CreateObject("Outlook.Application")
Set OutlookTask = OutlookApp.CreateItem(olTaskItem)
With OutlookTask
.Subject = "Date Case Began: " & [Forms]![frmERLR_Main]!
[DateCaseBegin] & " Action Type: " & [Forms]![frmERLR_Main]!
[ActionType] & " - " & [Forms]![frmERLR_Main]![ERLRAgencyName] & " -
Management POC: " & [Forms]![frmERLR_Main]![ManagementPOC]
.Body = "Issue: " & [Forms]![frmERLR_Main]![ERLRIssue] & " -
Recommendation: " & [Forms]![frmERLR_Main]![ERLRRec]
.ReminderSet = True
'Remind
.ReminderTime = [Forms]![frmReminder]![StartTime]
'Start Date
.StartDate = [Forms]![frmReminder]![StartDateE]
'Due .
.DueDate = [Forms]![frmReminder]![StartDateE]
.ReminderPlaySound = True
'Modify path.
.ReminderSoundFile = "C:\WINNT\Media\Ding.wav"
.Save
End With
End Function


When I call the function to add a task to outlook for the same day as
today and set the reminder time, it puts Sat 12/30/1899 in the
reminder date but the time is correct.


When I call the function for a date in the future, it gets the
reminder date correct, but defualts the time to 08:00AM.


Any ideas?
 
B

Brian Tillman

gumby said:
When I call the function for a date in the future, it gets the
reminder date correct, but defualts the time to 08:00AM.

The programmers hang out in microsoft.public.outlook.program_vba
 

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