Skip to main content

AppointmentLabelItem Class

Namespace: DevExpress.Maui.Scheduler

Assembly: DevExpress.Maui.Scheduler.dll

NuGet Package: DevExpress.Maui.Scheduler

Declaration

public class AppointmentLabelItem :
    SourceObjectContainer

The following members return AppointmentLabelItem objects:

Remarks

Labels specify colors that the scheduler uses to paint its appointments.

A scheduler view holds its labels in the LabelItems collection of the SchedulerDataStorage object assigned to the view’s DataStorage property. You can customize existing labels, remove them or add new ones. An individual label is an AppointmentLabelItem object. It provides the Caption and Color properties that you can use to specify a label’s display name and color.

To bind a scheduler view to an external data source of labels, set the SchedulerDataStorage.DataSource property to a DataSource object and bind the DataSource.AppointmentLabelsSource property to a collection of label objects. The DataSource.AppointmentLabelMappings property specifies how to convert source objects to appointment labels. See the example How to: Create Custom Labels.

Note

The LabelItems collection is always synchronous with the scheduler storage’s DataSource when the source is specified.

You can use the DataSource.CreateSourceObject event to create a source object that is assigned to a new item if the source objects’ type does not provide a parameterless constructor.

The appointment’s LabelId should be equal to a label’s Id to make the scheduler use the label’s color to paint the appointment.

The scheduler fills its label collection with the following default labels if you do not populate the collection manually or generate labels from a data source.

Color

Color Value

Display Name

Label Id (Int32 Value)

None

#949494

None

0

Important

#F15558

Important

1

Business

#FF7C11

Business

2

Personal

#FFBF22

Personal

3

Vacation

#FF6E86

Vacation

4

Must Attend

#9865b0

Must Attend

5

Travel Required

#756CFD

Travel Required

6

Needs Preparation

#0055D8

Needs Preparation

7

Birthday

#01B0EE

Birthday

8

Anniversary

#0097AD

Anniversary

9

Phone Call

#00C831

Phone Call

10

Inheritance

Object
DevExpress.Maui.Scheduler.Internal.NotifyPropertyChangedBase
SourceObjectContainer
AppointmentLabelItem
See Also