Skip to main content

AppointmentExporter.AppointmentExported Event

Occurs after an Appointment Exporter exports an appointment to iCalendar file or to MS Outlook Calendar storage.

Namespace: DevExpress.XtraScheduler.Exchange

Assembly: DevExpress.XtraScheduler.v24.2.Core.dll

Declaration

public event AppointmentExportedEventHandler AppointmentExported

Event Data

The AppointmentExported event's data class is AppointmentExportedEventArgs. The following properties provide information specific to this event:

Property Description
Appointment Gets the appointment for which the event was raised. Inherited from AppointmentEventArgs.

Remarks

Handle the AppointmentExported event for AppointmentExporter descendants when implementing appointment export.

This example illustrates the use of the AppointmentExporter.AppointmentExported event to add a custom property to the VEVENT component of the iCalendar object. The RFC 2446 defines the ORGANIZER property of an event, which specifies the calendar user who initiates a scheduling exchange, e.g. the one who proposes a group meeting. To add this property to an event exported to iCal format, the following code can be used:

using DevExpress.XtraScheduler.iCalendar;
using DevExpress.XtraScheduler.iCalendar.Components;
using DevExpress.XtraScheduler.iCalendar.Native;
// ...
    iCalendarExporter exporter = new iCalendarExporter(schedulerStorage);
    exporter.AppointmentExported += new AppointmentExportedEventHandler(exporter_AppointmentExported);

    void exporter_AppointmentExported(object sender, AppointmentExportedEventArgs e) 
    {
        iCalendarAppointmentExportedEventArgs args = (iCalendarAppointmentExportedEventArgs)e;
        iContentLineParameters parameters = new iContentLineParameters();
        iContentLineParam param1 = new iContentLineParam();
        parameters.Add(param1);
        CustomProperty property = new CustomProperty("ORGANIZER", parameters, 
            "MAILTO:Administrator@exchange.org");
        args.VEvent.CustomProperties.Add(property);
    }

To know more about iCalendar support, refer to the corresponding iCalendar Support article.

For more information on data exchange with the MS Outlook calendar, review the Synchronization with Microsoft Outlook article.

See Also