A Microsoft Outlook email forum. Outlook Banter

If this is your first visit, be sure to check out the FAQ by clicking the link above. You may have to register before you can post: click the register link above to proceed. To start viewing messages, select the forum that you want to visit from the selection below.

Go Back   Home » Outlook Banter forum » Microsoft Outlook Email Newsgroups » Outlook and VBA
Site Map Home Register Authors List Search Today's Posts Mark Forums Read Web Partners

Setting the ReminderTime gives strange results



 
 
Thread Tools Search this Thread Display Modes
  #1  
Old May 24th 06, 01:51 PM posted to microsoft.public.outlook.program_vba
Tim_Pope
external usenet poster
 
Posts: 1
Default Setting the ReminderTime gives strange results

I am using the following code in an Access database to create an Outlook Task
Item automatically. All is fine, except that the Reminder Date is always
incorect. Any suggestions as to why, or more impoortantly, how to fix the
problem, would be appreciated.

Public Sub SetReminder()

Dim OutlookApp As Outlook.Application
Dim OutlookTask As Outlook.TaskItem
Dim RemDate As Date

Set OutlookApp = CreateObject("Outlook.Application")
Set OutlookTask = OutlookApp.CreateItem(olTaskItem)
RemDate = Forms!frm_Action_New.RemindMe

With OutlookTask
.Subject = "Auto-Reminder for Item Reference - " & Me.Item_Ref
.Body = "Action:" & vbCrLf & Me.Action_Note & vbCrLf & vbCrLf _
& "Business Owner:" & vbCrLf & Me.Action_Bus_Owner & vbCrLf & vbCrLf _
& "Target date for completion:" & vbCrLf & Me.Target_Date
.StartDate = Date
.ReminderSet = True
.ReminderTime = RemDate & " " & CDate(#9:00:00 AM#)
.DueDate = Me.Target_Date
.Categories = "AutoReminder"
.ReminderPlaySound = True
.ReminderSoundFile = "C:\Windows\Media\Ding.wav"
.Save
End With

End Sub


  #2  
Old May 25th 06, 08:48 AM posted to microsoft.public.outlook.program_vba
Michael Bauer
external usenet poster
 
Posts: 435
Default Setting the ReminderTime gives strange results

Am Wed, 24 May 2006 05:51:02 -0700 schrieb Tim_Pope:

What time do you expect and what is it instead?

--
Viele Gruesse / Best regards
Michael Bauer - MVP Outlook
-- www.vbOffice.net --


I am using the following code in an Access database to create an Outlook

Task
Item automatically. All is fine, except that the Reminder Date is always
incorect. Any suggestions as to why, or more impoortantly, how to fix the
problem, would be appreciated.

Public Sub SetReminder()

Dim OutlookApp As Outlook.Application
Dim OutlookTask As Outlook.TaskItem
Dim RemDate As Date

Set OutlookApp = CreateObject("Outlook.Application")
Set OutlookTask = OutlookApp.CreateItem(olTaskItem)
RemDate = Forms!frm_Action_New.RemindMe

With OutlookTask
.Subject = "Auto-Reminder for Item Reference - " & Me.Item_Ref
.Body = "Action:" & vbCrLf & Me.Action_Note & vbCrLf & vbCrLf _
& "Business Owner:" & vbCrLf & Me.Action_Bus_Owner & vbCrLf & vbCrLf _
& "Target date for completion:" & vbCrLf & Me.Target_Date
.StartDate = Date
.ReminderSet = True
.ReminderTime = RemDate & " " & CDate(#9:00:00 AM#)
.DueDate = Me.Target_Date
.Categories = "AutoReminder"
.ReminderPlaySound = True
.ReminderSoundFile = "C:\Windows\Media\Ding.wav"
.Save
End With

End Sub

 




Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Allow results of an advance search to use the new email message Ehudsdagger Outlook - Using Contacts 0 May 16th 06 12:43 AM
Outlook Calendar Import results in events spanning 2 days, not 1 MikeM Outlook - Calandaring 1 April 23rd 06 10:42 AM
Is there a policy or registry setting for setting the default addr scsi Outlook - Installation 1 February 28th 06 01:19 PM
email shot/ search results Noha Diab Outlook - Using Contacts 2 February 14th 06 03:18 PM
How to get the results of an Advanced Find? Lucas Campos Outlook and VBA 1 January 27th 06 03:39 PM


All times are GMT +1. The time now is 11:16 AM.


Powered by vBulletin® Version 3.6.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.Search Engine Friendly URLs by vBSEO 2.4.0
Copyright ©2004-2025 Outlook Banter.
The comments are property of their posters.