need to send mail when remainder event caused

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I want to send email message when event remainder caused in outlook
i want to send the subject and body from the appointment to email
("(e-mail address removed)")
 
Try the Reminder event:

Dim WithEvents myolapp As Outlook.Application

Sub Initialize_handler()
Set myolapp = CreateObject("Outlook.Application")
End Sub

Private Sub myolapp_Reminder(ByVal Item As Object)
Dim objNewEmail As Outlook.MailItem

If Item.Class <> olAppointment Then Exit Sub
Set objNewEmail = myolapp.CreateItem(olMailItem)
objNewEmail.Subject = Item.Subject
objNewEmail.Body = Item.Body
objNewEmail.To = "(e-mail address removed)"
objNewEmail.Display

Set objNewEmail = Nothing
End Sub
 
Back
Top