windowsforms-devexpress-dot-xtrascheduler-dot-reporting-dot-timecellscontrolbase.md
Enables you to customize the appointment’s appearance by modifying the style elements when it is printed.
Namespace : DevExpress.XtraScheduler.Reporting
Assembly : DevExpress.XtraScheduler.v25.2.Reporting.dll
NuGet Package : DevExpress.Win.SchedulerReporting
public event AppointmentViewInfoCustomizingEventHandler AppointmentViewInfoCustomizing
Public Event AppointmentViewInfoCustomizing As AppointmentViewInfoCustomizingEventHandler
The AppointmentViewInfoCustomizing event's data class is AppointmentViewInfoCustomizingEventArgs. The following properties provide information specific to this event:
| Property | Description |
|---|---|
| ViewInfo | Provides access to the object which contains the information used to render the appointment. |
If you need to implement conditional styling based on the appointment data, handle the AppointmentViewInfoCustomizing event, and modify any appearance property using the appointment’s data as a condition. The event is analogous to the SchedulerControl.AppointmentViewInfoCustomizing event of the Scheduler control.
The following code snippet paints the appointment with a color obtained from the color schema of the associated resource:
private void dayViewTimeCells1_AppointmentViewInfoCustomizing(object sender,
AppointmentViewInfoCustomizingEventArgs e) {
SchedulerColorSchema schema = GetResourceColorSchema(e.ViewInfo.Resource);
e.ViewInfo.Appearance.BackColor = schema.Cell;
}
Private Sub dayViewTimeCells1_AppointmentViewInfoCustomizing(ByVal sender As Object, _
ByVal e As AppointmentViewInfoCustomizingEventArgs) _
Handles dayViewTimeCells1.AppointmentViewInfoCustomizing
Dim schema As SchedulerColorSchema = GetResourceColorSchema(e.ViewInfo.Resource)
e.ViewInfo.Appearance.BackColor = schema.Cell
End Sub
See Also