codeklopper
08-03-2010, 02:46 AM
I'm developping an Access 2003 application to register tasks/jobs. In addition I want the app to send a task to a collegae from a central mailbox (I have full access to this mailbox) in stead of my own mailbox.
The problem I have to solve is that the tasks are being send from my own mailbox.
the code I'm using:
Option Compare Database
Option Explicit
Function makeTask()
Dim OutlookApp As Outlook.Application
Dim outlookTask As Outlook.TaskItem
Set OutlookApp = CreateObject("Outlook.Application")
Set outlookTask = OutlookApp.CreateItem(olTaskItem)
With outlookTask
.Recipients.Add (getEMail)
.Owner = "nameOfMailbox"
.subject = getSubject
.Body = getOmschrijving
.ReminderSet = False
.DueDate = getDateEnd
.Assign
.Save
.Display
End With
Debug.Print outlookTask.DelegationState
End Function
Does anybody know how to save the task in the central mailbox and send it from this mailbox?
The problem I have to solve is that the tasks are being send from my own mailbox.
the code I'm using:
Option Compare Database
Option Explicit
Function makeTask()
Dim OutlookApp As Outlook.Application
Dim outlookTask As Outlook.TaskItem
Set OutlookApp = CreateObject("Outlook.Application")
Set outlookTask = OutlookApp.CreateItem(olTaskItem)
With outlookTask
.Recipients.Add (getEMail)
.Owner = "nameOfMailbox"
.subject = getSubject
.Body = getOmschrijving
.ReminderSet = False
.DueDate = getDateEnd
.Assign
.Save
.Display
End With
Debug.Print outlookTask.DelegationState
End Function
Does anybody know how to save the task in the central mailbox and send it from this mailbox?