SchedulerViewBase.ReverseAppointmentSelection(Appointment) Method
Switches the selection status of the specified appointment.
Namespace: DevExpress.XtraScheduler
Assembly: DevExpress.XtraScheduler.v24.1.dll
NuGet Package: DevExpress.Win.Scheduler
Declaration
Parameters
Name | Type | Description |
---|---|---|
apt | Appointment | An Appointment object that specifies the appointment. |
Remarks
Use the ReverseAppointmentSelection method to switch the selection state of a specific appointment in the current View.
If the ReverseAppointmentSelection method is called for an appointment which has not been selected, then the appointment is added to the SchedulerControl.SelectedAppointments collection and appears selected in the View. As a result, both the SchedulerControl.SelectedInterval and SchedulerViewBase.SelectedInterval properties take the time interval value that corresponds to the specified appointment.
Calling the ReverseAppointmentSelection method for a selected appointment removes it from the SchedulerControl.SelectedAppointments collection and so makes it appear unselected. In this case, the selection is applied to the View in the following manner. If the specified appointment was the only selected appointment within the scheduler control, the time interval that corresponds to the specified appointment appears selected. If there was more than one appointment selected, the ReverseAppointmentSelection method is called, no time interval appears selected and only the other appointments in the SchedulerControl.SelectedAppointments collection are displayed selected within the View.
Note that a call to the ReverseAppointmentSelection method raises the SchedulerControl.SelectionChanged event.