Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

AppointmentItem.CreateException(AppointmentType, Int32) Method

OBSOLETE

Use the following API instead: scheduler.GetOccurrenceOrException(pattern, recurrenceIndex: 0).Type = AppointmentType.ChangedOccurrence;

Creates an appointment that is an exception in a recurring series.

Namespace: DevExpress.Xpf.Scheduling

Assembly: DevExpress.Xpf.Scheduling.v24.2.dll

NuGet Package: DevExpress.Wpf.Scheduling

#Declaration

[Obsolete("Use the following API instead: scheduler.GetOccurrenceOrException(pattern, recurrenceIndex: 0).Type = AppointmentType.ChangedOccurrence;", false)]
public AppointmentItem CreateException(
    AppointmentType type,
    int recurrenceIndex
)

#Parameters

Name Type Description
type AppointmentType

An AppointmentType value that specifies the type of the exception.

recurrenceIndex Int32

A zero-based integer which specifies the new appointment’s index in the recurring series.

#Returns

Type Description
AppointmentItem

An AppointmentItem object which is the newly created exception.

#Remarks

The CreateException method is obsolete. Use the GetOccurrenceOrException method instead.

You can also manually create an exception. Create a new AppointmentItem, set its type to ChangedOccurrence or DeletedOccurrence, and use the SetPatternReference method to embed the item into a recurring chain. Add the item to the AppointmentItems collection.

See Also