Лучший отвечающий
Outlook 2010 Отправка напоминания в календаре на Email перерчисленных в поле "To:"

Вопрос
-
Коллеги, помогите решить данную задачу, необходимо что бы событие которое отмечено в календаре помино напоминания в окне reminders так же падало людям чьи email адреса перечислены в поле "To:"
Я так понимаю, что данная задача решается через VBS (в Outlook нажать alt+F11) или макросы, но как? ума не приложу так как с макросами не знаком.
Помогите плиз.
16 мая 2013 г. 7:34
Ответы
-
Ответ:
Dim WithEvents olkReminders As Outlook.Reminders Private Sub Application_Quit() Set olkReminders = Nothing End Sub Private Sub Application_Startup() Set olkReminders = Application.Reminders End Sub Private Sub olkReminders_ReminderFire(ByVal ReminderObject As Reminder) 'On the next line edit the triggering category name as desired.' Const REMINDER_CATEGORY_NAME = "Reminders" Dim olkApt As Outlook.AppointmentItem, _ olkMsg As Outlook.MailItem, _ olkRcp As Outlook.Recipient If ReminderObject.Item.Class = olAppointment Then Set olkApt = ReminderObject.Item If olkApt.MeetingStatus = olMeeting Then If InStr(1, olkApt.Categories, REMINDER_CATEGORY_NAME) Then If olkApt.Organizer = Session.CurrentUser Then Set olkMsg = Application.CreateItem(olMailItem) With olkMsg For Each olkRcp In olkApt.Recipients Select Case olkRcp.Type 'On the next line remove olOptional if you only want reminders sent to required attendees.' Case olRequired, olOptional .Recipients.Add olkRcp.Address End Select Next 'On the next line edit the message subject as desired.' .Subject = "Meeting Reminder" .BodyFormat = olFormatPlain 'On the next 5 lines edit the message body as desired.' .Body = "This is a reminder of the following meeting:" & vbCrLf _ & "Subject.: " & olkApt.Subject & vbCrLf _ & "Starts..: " & olkApt.Start & "(" & olkApt.StartTimeZone & ")" & vbCrLf _ & "Ends....: " & olkApt.End & "(" & olkApt.StartTimeZone & ")" & vbCrLf _ & "Location: " & olkApt.Location .Send End With End If End If End If End If Set olkApt = Nothing Set olkMsg = Nothing Set olkRcp = Nothing End Sub
Помогите плиз.
- Помечено в качестве ответа Jury Maksimov 17 мая 2013 г. 8:45
17 мая 2013 г. 8:45
Все ответы
-
Ответ:
Dim WithEvents olkReminders As Outlook.Reminders Private Sub Application_Quit() Set olkReminders = Nothing End Sub Private Sub Application_Startup() Set olkReminders = Application.Reminders End Sub Private Sub olkReminders_ReminderFire(ByVal ReminderObject As Reminder) 'On the next line edit the triggering category name as desired.' Const REMINDER_CATEGORY_NAME = "Reminders" Dim olkApt As Outlook.AppointmentItem, _ olkMsg As Outlook.MailItem, _ olkRcp As Outlook.Recipient If ReminderObject.Item.Class = olAppointment Then Set olkApt = ReminderObject.Item If olkApt.MeetingStatus = olMeeting Then If InStr(1, olkApt.Categories, REMINDER_CATEGORY_NAME) Then If olkApt.Organizer = Session.CurrentUser Then Set olkMsg = Application.CreateItem(olMailItem) With olkMsg For Each olkRcp In olkApt.Recipients Select Case olkRcp.Type 'On the next line remove olOptional if you only want reminders sent to required attendees.' Case olRequired, olOptional .Recipients.Add olkRcp.Address End Select Next 'On the next line edit the message subject as desired.' .Subject = "Meeting Reminder" .BodyFormat = olFormatPlain 'On the next 5 lines edit the message body as desired.' .Body = "This is a reminder of the following meeting:" & vbCrLf _ & "Subject.: " & olkApt.Subject & vbCrLf _ & "Starts..: " & olkApt.Start & "(" & olkApt.StartTimeZone & ")" & vbCrLf _ & "Ends....: " & olkApt.End & "(" & olkApt.StartTimeZone & ")" & vbCrLf _ & "Location: " & olkApt.Location .Send End With End If End If End If End If Set olkApt = Nothing Set olkMsg = Nothing Set olkRcp = Nothing End Sub
Помогите плиз.
- Помечено в качестве ответа Jury Maksimov 17 мая 2013 г. 8:45
17 мая 2013 г. 8:45 -
Юрий, не могли бы вы подробнее описать, как добавить этот скрипт в Outlook?
У меня Outlook 2016. Exchange 2010.
Добавил в дефолтный модуль ThisOutlookSession - не работает.
Спасибо.
22 июня 2018 г. 8:57