corelibraries-devexpress-dot-xtrascheduler-dot-appointment-079287da.md
Gets or sets the end date and time of the appointment.
Namespace : DevExpress.XtraScheduler
Assembly : DevExpress.XtraScheduler.v25.2.Core.dll
NuGet Package : DevExpress.Scheduler.Core
DateTime End { get; set; }
Property [End] As Date
| Type | Description |
|---|---|
| DateTime |
A DateTime value representing the end of the appointment.
|
The End property is usually specified by the Appointment.Start and Appointment.Duration properties, and is always calculated as End = Start + Duration. When setting the End property, the Appointment.Start property retains its value, and the Appointment.Duration is changed according to the new value of the End property. If the new Appointment.End property’s value is less than the Appointment.Start property’s value, an exception is raised.
The following code snippets (auto-collected from DevExpress Examples) contain references to the End property.
Note
The algorithm used to collect these code examples remains a work in progress. Accordingly, the links and snippets below may produce inaccurate results. If you encounter an issue with code examples below, please use the feedback form on this page to report the issue.
winforms-scheduler-sync-with-ews/CS/EWSSyncExample/Synchronizer.cs#L252
exchangeAppointment.Start = schedulerAppointment.Start;
exchangeAppointment.End = schedulerAppointment.End;
winforms-scheduler-recurrence-series-occurrencecalculator/CS/OccurrenceCalculatorSample/Form1.cs#L29
apt.Start = DateTime.Today.AddHours(10);
apt.End = apt.Start.AddHours(3);
apt.RecurrenceInfo.Type = RecurrenceType.Daily;
winforms-scheduler-enforce-task-dependencies-gantt-view/CS/GanttRestrictions/Form1.cs#L55
if (dep.Type == AppointmentDependencyType.FinishToStart) {
DateTime checkTime = schedulerDataStorage1.Appointments.Items.GetAppointmentById(dep.ParentId).End;
if (apt.Start < checkTime)
winforms-scheduler-display-custom-tooltips/CS/Form1.cs#L95
apt.Start = baseTime.AddHours(1);
apt.End = baseTime.AddHours(2);
apt.Subject = "Test";
apt.Start = start.AddDays(day).AddHours(GetRandomDouble(rnd, 0, 18));
apt.End = apt.Start.AddHours(GetRandomDouble(rnd, 0.5, 6.0));
int subjectIndex = rnd.Next(0, subjects.Length);
winforms-scheduler-import-google-calendar/VB/GoogleCalendarExample/RecurrencePatternParser.vb#L46
pattern.Start = start
pattern.End = [end]
iCalendarHelper.ApplyRecurrenceInfo(pattern.RecurrenceInfo, start, rule)
winforms-scheduler-sync-with-ews/VB/EWSSyncExample/Synchronizer.vb#L238
exchangeAppointment.Start = schedulerAppointment.Start
exchangeAppointment.End = schedulerAppointment.End
winforms-scheduler-recurrence-series-occurrencecalculator/VB/OccurrenceCalculatorSample/Form1.vb#L27
apt.Start = Date.Today.AddHours(10)
apt.End = apt.Start.AddHours(3)
apt.RecurrenceInfo.Type = RecurrenceType.Daily
winforms-scheduler-enforce-task-dependencies-gantt-view/VB/GanttRestrictions/Form1.vb#L45
If dep.Type = AppointmentDependencyType.FinishToStart Then
Dim checkTime As Date = schedulerDataStorage1.Appointments.Items.GetAppointmentById(dep.ParentId).End
If apt.Start < checkTime Then Return True
winforms-scheduler-display-custom-tooltips/VB/Form1.vb#L79
apt.Start = baseTime.AddHours(1)
apt.End = baseTime.AddHours(2)
apt.Subject = "Test"
See Also