Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Adding Task to Outlook Task List via Access97

Status
Not open for further replies.

Tranquilo

Technical User
Oct 30, 2001
13
0
0
US

I'm using a database to run the yearly budget for a large chain of stores. To do this we have to figure in stores that will open or close in the future removing the recurring costs for those stores that will close and figuring in other costs for those that will open. This requires that I proactively enter the approximate opening/closing date, sometimes a year in advance.

Unfortunately, there is also an email that must be sent out to the corporate office on the exact day that a store opens or closes. How can I get Access use the opening/closing date to schedule a notice on the task list to remind myself to send out the email?

TIA
 
Hi ya Tranquilo

Try this. Make sure you have the Outlook Object Library enabled.

Sub StoreOpenCloseReminder()
Dim MyApp As Outlook.Application
Dim MyTaskList As Outlook.TaskItem

Set MyApp = CreateObject("Outlook.Application")

Set MyTaskList = MyApp.CreateItem(Outlook.olTaskItem)

With MyTaskList
.DueDate = "Your opening/closing date field"
.ReminderSet = True
.ReminderTime = "Your opening/closing date field"
& "Reminder Time" ' eg Reminder time = 09:00:00
.Subject = "Store Opening/Closing"
.Close (olSave)
End With

End Sub

Hope this solves your problem.
Jo :eek:)
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top