Events

Outlook events can be found in two places: Common API and Outlook/Mailbox API.
The Common API contains six basic events which were added first.
The Outlook/Mailbox API contains more events which were added later.


Common API - Events

The Common API contains the following events.

AppointmentTimeChanged(Added 1.7)
AttachmentsChanged(Added 1.8)
EnhancedLocationsChanged(Added 1.8)
OfficeThemeChanged(preview)
RecipientsChanged(Added 1.7)
RecurrenceChanged(Added 1.7)
AppointmentTimeChanged
(Added 1.7)
AttachmentsChanged
(Added 1.8)
EnhancedLocationsChanged
(Added 1.8)
OfficeThemeChanged
(preview)
RecipientsChanged
(Added 1.7)
RecurrenceChanged
(Added 1.7)

Outlook/Mailbox API - Events

These events are also known as Event Based Activation.

link - learn.microsoft.com/en-us/office/dev/add-ins/outlook/autolaunch 

This feature enables your add-in to run tasks based on certain events, particularly for operations that apply to every item.
You can integrate these with task panes and UI-less functionality.

onAppointmentAttachmentsChanged(Added 1.11) Occurs when adding ot removing attachments from an appointment
onAppointmentAttendeesChanged(Added 1.11) Occurs when adding ot removing attendees from an appointment
onAppointmentRecurrenceChanged(Added 1.11) Occurs when adding, changing or removing recurrence details while composing an appointment
onAppointmentSend(Added 1.12) Occurs when sending an appointment. Part of Smart Alerts.
onAppointmentTimeChanged(Added 1.11) Occurs when the date or time is changed on an appointment
onInfoBarDismissClicked(Added 1.11) Occurs when a notification is dismissed while composing a message or appointment item. Only the add-in that added the notification will be notified.
onMessageAttachmentsChanged(Added 1.11) Occurs when adding or removing attachments while composing a message
onMessageRecipientsChanged(Added 1.11) Occurs when adding or removing recipients from a message
onMessageSend(Added 1.12) Occurs when sending a message. Part of Smart Alerts.
onNewAppointmentOrganizer(Added 1.10) Occurs when creating a new appointment but not when editing an existing one
onNewMessageCompose(Added 1.10) Occurs when composing a new message (reply, reply all or forward). Not draft
onAppointmentAttachmentsChanged
(Added 1.11) Occurs when adding ot removing attachments from an appointment
onAppointmentAttendeesChanged
(Added 1.11) Occurs when adding ot removing attendees from an appointment
onAppointmentRecurrenceChanged
(Added 1.11) Occurs when adding, changing or removing recurrence details while composing an appointment
onAppointmentSend
(Added 1.12) Occurs when sending an appointment. Part of Smart Alerts.
onAppointmentTimeChanged
(Added 1.11) Occurs when the date or time is changed on an appointment
onInfoBarDismissClicked
(Added 1.11) Occurs when a notification is dismissed while composing a message or appointment item. Only the add-in that added the notification will be notified.
onMessageAttachmentsChanged
(Added 1.11) Occurs when adding or removing attachments while composing a message
onMessageRecipientsChanged
(Added 1.11) Occurs when adding or removing recipients from a message
onMessageSend
(Added 1.12) Occurs when sending a message. Part of Smart Alerts.
onNewAppointmentOrganizer
(Added 1.10) Occurs when creating a new appointment but not when editing an existing one
onNewMessageCompose
(Added 1.10) Occurs when composing a new message (reply, reply all or forward). Not draft

<VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides" xsi:type="VersionOverridesV1_0"> 
  <VersionOverrides xmlns="http://schemas.microsoft.com/office/mailappversionoverrides/1.1" xsi:type="VersionOverridesV1_1">
    <Requirements>
      <bt:Sets DefaultMinVersion="1.3">
        <bt:Set Name="Mailbox" />
      </bt:Sets>
    </Requirements>
    <Hosts>
      <Host xsi:type="MailHost">
        <!-- Event-based activation happens in a lightweight runtime.-->
        <Runtimes>
          <!-- HTML file including reference to or inline JavaScript event handlers.
               This is used by Outlook on the web. -->
          <Runtime resid="WebViewRuntime.Url">
            <!-- JavaScript file containing event handlers. This is used by Outlook Desktop. -->
            <Override type="javascript" resid="JSRuntime.Url"/>
          </Runtime>
        </Runtimes>
        <DesktopFormFactor>
          <FunctionFile resid="Commands.Url" />
          <ExtensionPoint xsi:type="MessageReadCommandSurface">

          </ExtensionPoint>

          <!-- Enable launching the add-in on the included events. -->
          <ExtensionPoint xsi:type="LaunchEvent">
            <LaunchEvents>
              <LaunchEvent Type="OnNewMessageCompose" FunctionName="onMessageComposeHandler"/>
              <LaunchEvent Type="OnNewAppointmentOrganizer" FunctionName="onAppointmentComposeHandler"/>
            </LaunchEvents>
            <!-- Identifies the runtime to be used (also referenced by the Runtime element). -->
            <SourceLocation resid="WebViewRuntime.Url"/>
          </ExtensionPoint>
        </DesktopFormFactor>
      </Host>
    </Hosts>
  </VersionOverrides>
</VersionOverrides>


© 2023 Better Solutions Limited. All Rights Reserved. © 2023 Better Solutions Limited TopPrevNext