menu

MAUI

  • User Guide
  • Demos
  • Support
  • Forums
  • Download
Class SfScheduler - MAUI API Reference | Syncfusion

    Show / Hide Table of Contents

    Class SfScheduler

    Represents the control which allows the user to create and manage appointments.

    Inheritance
    System.Object
    SfScheduler
    Implements
    Microsoft.Maui.IContentView
    Microsoft.Maui.IView
    Microsoft.Maui.IElement
    Microsoft.Maui.ITransform
    Microsoft.Maui.IPadding
    Microsoft.Maui.ICrossPlatformLayout
    Namespace: Syncfusion.Maui.Scheduler
    Assembly: Syncfusion.Maui.Scheduler.dll
    Syntax
    public class SfScheduler : View, IContentView, IView, IElement, ITransform, IPadding, ICrossPlatformLayout, IScheduler, ISchedulerViewInfo, IViewHeader, IDragAndDropInfo, IHeader, ISchedulerTouchGesture, IWeekHeader, IReminderInfo, IResourceViewInfo, ISchedulerKeyListener, IAgendaViewInfo, IAppointmentViewInfo, ISchedulerCommon, IInteractionInfo, IParentThemeElement, IThemeElement
    Examples

    The following code demonstrates, how to bind AppointmentsSource and populate appointments in the scheduler control.

    # [C#](#tab/tabid-1)
    public class Meeting : INotifyPropertyChanged
    {
       private DateTime from, to;
       private string eventName;
       private bool isAllDay;
       private TimeZoneInfo startTimeZone, endTimeZone;
       private Brush background;
       private ObservableCollection<DateTime> recurrenceExceptionDates;
       private string rRUle;
       private object recurrenceId;
       private object id;
       private string notes;
       public Meeting()
       {
           recurrenceExceptionDates = new ObservableCollection<DateTime>();
       }
       public event PropertyChangedEventHandler PropertyChanged;
       public DateTime From
       {
           get { return from; }
           set
           {
               from = value;
               this.RaiseOnPropertyChanged(nameof(From));
           }
       }
       public DateTime To
       {
           get { return to; }
           set
           {
               to = value;
               this.RaiseOnPropertyChanged(nameof(To));
           }
       }
       public bool IsAllDay
       {
           get { return isAllDay; }
           set
           {
               isAllDay = value;
               this.RaiseOnPropertyChanged(nameof(IsAllDay));
           }
       }
       public string EventName
       {
           get { return eventName; }
           set
           {
               eventName = value;
               this.RaiseOnPropertyChanged(nameof(EventName));
           }
       }
       public string Notes
       {
           get { return notes; }
           set
           {
               notes = value;
               this.RaiseOnPropertyChanged(nameof(Notes));
           }
       }
       public TimeZoneInfo StartTimeZone
       {
           get { return startTimeZone; }
           set
           {
               startTimeZone = value;
               this.RaiseOnPropertyChanged(nameof(StartTimeZone));
           }
       }
       public TimeZoneInfo EndTimeZone
       {
           get { return endTimeZone; }
           set
           {
               endTimeZone = value;
              this.RaiseOnPropertyChanged(nameof(EndTimeZone));
           }
       }
       public Brush Background
       {
           get { return background; }
           set
           {
              background = value;
              this.RaiseOnPropertyChanged(nameof(Background));
           }
       }
       public object RecurrenceId
       {
           get { return recurrenceId; }
          set
           {
               recurrenceId = value;
               this.RaiseOnPropertyChanged(nameof(RecurrenceId));
           }
       }
       public object Id
       {
           get { return id; }
           set
          {
               id = value;
               this.RaiseOnPropertyChanged(nameof(Id));
           }
       }
       public string RecurrenceRule
       {
           get { return rRUle; }
           set
          {
               rRUle = value;
               this.RaiseOnPropertyChanged(nameof(RecurrenceRule));
           }
       }
       public ObservableCollection<DateTime> RecurrenceExceptions
       {
           get { return recurrenceExceptionDates; }
           set
           {
               recurrenceExceptionDates = value;
               this.RaiseOnPropertyChanged(nameof(RecurrenceExceptions));
           }
       }
       private void RaiseOnPropertyChanged(string propertyName)
       {
           this.PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
       }
    }
    # [C#](#tab/tabid-2)
    public class SchedulerViewModel
    {
       private List<string> subjectCollection;
       private List<string> noteCollection;
       private List<Brush> colorCollection;
       public SchedulerViewModel()
       {
           this.CreateSubjectCollection();
           this.CreateColorCollection();
           this.CreateNoteCollection();
           this.IntializeAppoitments();
       }
       public ObservableCollection<Meeting> Events { get; set; }
       private void CreateNoteCollection()
       {
           this.noteCollection = new List<string>();
           this.noteCollection.Add("Consulting firm laws with business advisers");
           this.noteCollection.Add("Execute Project Scope");
           this.noteCollection.Add("Project Scope & Deliverables");
           this.noteCollection.Add("Executive summary");
           this.noteCollection.Add("Try to reduce the risks");
           this.noteCollection.Add("Encourages the integration of mind, body, and spirit");
           this.noteCollection.Add("Execute Project Scope");
           this.noteCollection.Add("Project Scope & Deliverables");
           this.noteCollection.Add("Executive summary");
           this.noteCollection.Add("Try to reduce the risk");
       }
       private void IntializeAppoitments()
       {
           this.Events = new ObservableCollection<Meeting>();
           Random randomTime = new Random();
           List<Point> randomTimeCollection = this.GettingTimeRanges();
           DateTime date;
           DateTime dateFrom = DateTime.Now.AddDays(-50);
           DateTime dateTo = DateTime.Now.AddDays(50);
           for (date = dateFrom; date < dateTo; date = date.AddDays(1))
           {
               if (date.Day % 7 != 0)
               {
                   for (int additionalAppointmentIndex = 0; additionalAppointmentIndex < 1; additionalAppointmentIndex++)
                   {
                      var meeting = new Meeting();
                       int hour = randomTime.Next((int)randomTimeCollection[additionalAppointmentIndex].X, (int)randomTimeCollection[additionalAppointmentIndex].Y);
                       meeting.From = new DateTime(date.Year, date.Month, date.Day, hour, 0, 0);
                       meeting.To = meeting.From.AddHours(1);
                       meeting.EventName = this.subjectCollection[randomTime.Next(9)];
                       meeting.Background = this.colorCollection[randomTime.Next(10)];
                       meeting.IsAllDay = false;
                       meeting.Notes = this.noteCollection[randomTime.Next(10)];
                       meeting.StartTimeZone = string.Empty;
                       meeting.EndTimeZone = string.Empty;
                       this.Events.Add(meeting);
                  }
               }
               else
               {
                   var meeting = new Meeting();
                   meeting.From = new DateTime(date.Year, date.Month, date.Day, randomTime.Next(9, 11), 0, 0);
                   meeting.To = meeting.From.AddDays(2).AddHours(1);
                   meeting.EventName = this.subjectCollection[randomTime.Next(10)];
                   meeting.Background = this.colorCollection[randomTime.Next(10)];
                   meeting.IsAllDay = true;
                   meeting.Notes = this.noteCollection[randomTime.Next(9)];
                   meeting.StartTimeZone = string.Empty;
                   meeting.EndTimeZone = string.Empty;
                   this.Events.Add(meeting);
              }
           }
       }
       private void CreateSubjectCollection()
       {
           this.subjectCollection = new List<string>();
           this.subjectCollection.Add("General Meeting");
           this.subjectCollection.Add("Plan Execution");
           this.subjectCollection.Add("Project Plan");
           this.subjectCollection.Add("Consulting");
           this.subjectCollection.Add("Performance Check");
           this.subjectCollection.Add("Support");
           this.subjectCollection.Add("Development Meeting");
           this.subjectCollection.Add("Scrum");
           this.subjectCollection.Add("Project Completion");
           this.subjectCollection.Add("Release updates");
           this.subjectCollection.Add("Performance Check");
       }
       private List<Point> GettingTimeRanges()
       {
           List<Point> randomTimeCollection = new List<Point>();
           randomTimeCollection.Add(new Point(9, 11));
           randomTimeCollection.Add(new Point(12, 14));
           randomTimeCollection.Add(new Point(15, 17));
           return randomTimeCollection;
       }
       private void CreateColorCollection()
       {
           this.colorCollection = new List<Brush>();
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF8B1FA9")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FFD20100")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FFFC571D")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF36B37B")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF3D4FB5")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FFE47C73")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF636363")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF85461E")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF0F8644")));
           this.colorCollection.Add(new SolidColorBrush(Color.FromArgb("#FF01A1EF")));
       }
    }
    # [XAML](#tab/tabid-3)
    <schedule:SfScheduler x:Name="Scheduler"
                          AppointmentsSource="{Binding Events}">
       <schedule:SfScheduler.AppointmentMapping>
           <schedule:SchedulerAppointmentMapping
               Subject = "EventName"
               StartTime="From"
               EndTime="To"
               Background="Background"
               IsAllDay="IsAllDay"
               StartTimeZone="StartTimeZone"
               EndTimeZone="EndTimeZone"
               RecurrenceExceptionDates="RecurrenceExceptions"
               RecurrenceRule="RecurrenceRule"
               RecurrenceId="RecurrenceId"/>
       </schedule:SfScheduler.AppointmentMapping>
       <schedule:SfScheduler.BindingContext>
           <local:SchedulerViewModel />
       </schedule:SfScheduler.BindingContext>
    </schedule:SfScheduler>

    Constructors

    SfScheduler()

    Initializes a new instance of the SfScheduler class.

    Declaration
    public SfScheduler()

    Fields

    AgendaViewProperty

    Identifies the AgendaView dependency property.

    Declaration
    public static readonly BindableProperty AgendaViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the AgendaView bindable property.

    AllowAppointmentDragProperty

    Identifies the AllowAppointmentDrag dependency property.

    Declaration
    public static readonly BindableProperty AllowAppointmentDragProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for AllowAppointmentDrag dependency property

    AllowedViewsProperty

    Identifies the AllowedViews dependency property.

    Declaration
    public static readonly BindableProperty AllowedViewsProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for AllowedViews dependency property.

    AllowViewNavigationProperty

    Identifies the AllowViewNavigation dependency property.

    Declaration
    public static readonly BindableProperty AllowViewNavigationProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for AllowViewNavigation dependency property.

    AppointmentBorderStyleProperty

    Identifies the AppointmentBorderStyle dependency property.

    Declaration
    public static readonly BindableProperty AppointmentBorderStyleProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for AppointmentBorderStyle dependency property.

    AppointmentMappingProperty

    Identifies the AppointmentMapping dependency property.

    Declaration
    public static readonly BindableProperty AppointmentMappingProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the AppointmentMapping bindable property.

    AppointmentsSourceProperty

    Identifies the AppointmentsSource dependency property.

    Declaration
    public static readonly BindableProperty AppointmentsSourceProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the AppointmentsSource bindable property.

    AppointmentTextStyleProperty

    Identifies the AppointmentTextStyle dependency property.

    Declaration
    public static readonly BindableProperty AppointmentTextStyleProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for AppointmentTextStyle dependency property.

    BusyIndicatorTemplateProperty

    Identifies the BusyIndicatorTemplate dependency property.

    Declaration
    public static readonly BindableProperty BusyIndicatorTemplateProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for BusyIndicatorTemplate dependency property.

    CalendarTypeProperty

    Identifies the CalendarType dependency property.

    Declaration
    public static readonly BindableProperty CalendarTypeProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for CalendarType dependency property.

    CellBorderBrushProperty

    Identifies the CellBorderBrush dependency property.

    Declaration
    public static readonly BindableProperty CellBorderBrushProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for CellBorderBrush dependency property.

    CellSelectionViewProperty

    Identifies the CellSelectionView dependency property.

    Declaration
    public static readonly BindableProperty CellSelectionViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the CellSelectionView bindable property.

    DaysViewProperty

    Identifies the DaysView dependency property.

    Declaration
    public static readonly BindableProperty DaysViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the DaysView bindable property.

    DisabledDateBackgroundProperty

    Identifies the DisabledDateBackground dependency property.

    Declaration
    public static readonly BindableProperty DisabledDateBackgroundProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the DisabledDateBackground bindable property.

    DisabledDateTextStyleProperty

    Identifies the DisabledDateTextStyle bindable property.

    Declaration
    public static readonly BindableProperty DisabledDateTextStyleProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for DisabledDateTextStyle dependency property.

    DisplayDateProperty

    Identifies the DisplayDate dependency property.

    Declaration
    public static readonly BindableProperty DisplayDateProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for DisplayDate dependency property.

    DoubleTappedCommandProperty

    Identifies the DoubleTappedCommand dependency property.

    Declaration
    public static readonly BindableProperty DoubleTappedCommandProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for DoubleTappedCommand dependency property.

    DragDropSettingsProperty

    Identifies the DragDropSettings dependency property.

    Declaration
    public static readonly BindableProperty DragDropSettingsProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for DragDropSettings dependency property

    EnableReminderProperty

    Identifies the EnableReminder dependency property.

    Declaration
    public static readonly BindableProperty EnableReminderProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for EnableReminder dependency property

    FirstDayOfWeekProperty

    Identifies the FirstDayOfWeek dependency property.

    Declaration
    public static readonly BindableProperty FirstDayOfWeekProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for FirstDayOfWeek dependency property.

    HeaderViewProperty

    Identifies the HeaderView dependency property.

    Declaration
    public static readonly BindableProperty HeaderViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the HeaderView bindable property.

    LongPressedCommandProperty

    Identifies the LongPressedCommand dependency property.

    Declaration
    public static readonly BindableProperty LongPressedCommandProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for LongPressedCommand dependency property.

    MaximumDateTimeProperty

    Identifies the MaximumDateTime dependency property.

    Declaration
    public static readonly BindableProperty MaximumDateTimeProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for MaximumDateTime dependency property.

    MinimumDateTimeProperty

    Identifies the MinimumDateTime dependency property.

    Declaration
    public static readonly BindableProperty MinimumDateTimeProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for MinimumDateTime dependency property.

    MonthViewProperty

    Identifies the MonthView dependency property.

    Declaration
    public static readonly BindableProperty MonthViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the MonthView bindable property.

    QueryAppointmentsCommandProperty

    Identifies the QueryAppointmentsCommand dependency property.

    Declaration
    public static readonly BindableProperty QueryAppointmentsCommandProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for QueryAppointmentsCommand dependency property.

    ResourceViewProperty

    Identifies the ResourceView dependency property.

    Declaration
    public static readonly BindableProperty ResourceViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ResourceView dependency property.

    SelectedAppointmentBackgroundProperty

    Identifies the SelectedAppointmentBackground dependency property.

    Declaration
    public static readonly BindableProperty SelectedAppointmentBackgroundProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the SelectedAppointmentBackground bindable property.

    SelectedCellBackgroundProperty

    Identifies the SelectedCellBackground dependency property.

    Declaration
    public static readonly BindableProperty SelectedCellBackgroundProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the SelectedCellBackground bindable property.

    SelectedDateProperty

    Identifies the SelectedDate dependency property.

    Declaration
    public static readonly BindableProperty SelectedDateProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for SelectedDate dependency property.

    SelectionChangedCommandProperty

    Identifies the SelectionChangedCommand dependency property.

    Declaration
    public static readonly BindableProperty SelectionChangedCommandProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for SelectionChangedCommand dependency property.

    ShowAllowedViewsProperty

    Identifies the ShowAllowedViews dependency property.

    Declaration
    public static readonly BindableProperty ShowAllowedViewsProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ShowAllowedViews dependency property.

    ShowBusyIndicatorProperty

    Identifies the ShowBusyIndicator dependency property.

    Declaration
    public static readonly BindableProperty ShowBusyIndicatorProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ShowBusyIndicator dependency property.

    ShowDatePickerButtonProperty

    Identifies the ShowDatePickerButton dependency property.

    Declaration
    public static readonly BindableProperty ShowDatePickerButtonProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ShowDatePickerButton dependency property.

    ShowNavigationArrowsProperty

    Identifies the ShowNavigationArrows dependency property.

    Declaration
    public static readonly BindableProperty ShowNavigationArrowsProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ShowNavigationArrows dependency property.

    ShowTodayButtonProperty

    Identifies the ShowTodayButton dependency property.

    Declaration
    public static readonly BindableProperty ShowTodayButtonProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ShowTodayButton dependency property.

    ShowWeekNumberProperty

    Identifies the ShowWeekNumber dependency property.

    Declaration
    public static readonly BindableProperty ShowWeekNumberProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the ShowWeekNumber bindable property.

    TappedCommandProperty

    Identifies the TappedCommand dependency property.

    Declaration
    public static readonly BindableProperty TappedCommandProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for TappedCommand dependency property.

    TimelineViewProperty

    Identifies the TimelineView dependency property.

    Declaration
    public static readonly BindableProperty TimelineViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the TimelineView bindable property.

    TimeZoneProperty

    Identifies the TimeZone dependency property.

    Declaration
    public static readonly BindableProperty TimeZoneProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for TimeZone dependency property.

    TodayHighlightBrushProperty

    Identifies the TodayHighlightBrush dependency property.

    Declaration
    public static readonly BindableProperty TodayHighlightBrushProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for TodayHighlightBrush dependency property.

    TodayTextStyleProperty

    Identifies the TodayTextStyle dependency property.

    Declaration
    public static readonly BindableProperty TodayTextStyleProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for TodayTextStyle dependency property.

    ViewChangedCommandProperty

    Identifies the ViewChangedCommand dependency property.

    Declaration
    public static readonly BindableProperty ViewChangedCommandProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for ViewChangedCommand dependency property.

    ViewProperty

    Identifies the View dependency property.

    Declaration
    public static readonly BindableProperty ViewProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    The identifier for View dependency property.

    WeekNumberStyleProperty

    Identifies the WeekNumberStyle dependency property.

    Declaration
    public static readonly BindableProperty WeekNumberStyleProperty
    Field Value
    Type Description
    Microsoft.Maui.Controls.BindableProperty

    Identifies the WeekNumberStyle bindable property.

    Properties

    AgendaView

    Gets or sets properties which allows to customize the agenda view of the SfScheduler.

    Declaration
    public SchedulerAgendaView AgendaView { get; set; }
    Property Value
    Type Description
    SchedulerAgendaView

    The properties settings used to customize the agenda view.

    Examples

    The below examples shows, how to use the agenda view settings of the SfScheduler.

    • XAML
    • C#
    • C#
    <scheduler:SfScheduler x:Name="scheduler"
                      View="Agenda" AllowedViews="Month,Agenda">
       <scheduler:SfScheduler.AgendaView>
           <scheduler:SchedulerAgendaView>
               <scheduler:SchedulerAgendaView.DayHeaderSettings>
                   <scheduler:SchedulerDayHeaderSettings Background = "LightGreen"
                                                         Width="100" />
               </scheduler:SchedulerAgendaView.DayHeaderSettings>
               <scheduler:SchedulerAgendaView.WeekHeaderSettings>
                   <scheduler:SchedulerWeekHeaderSettings Background = "LightGreen"
                                                          Height="200" />
               </scheduler:SchedulerAgendaView.WeekHeaderSettings>
               <scheduler:SchedulerAgendaView.MonthHeaderSettings>
                   <scheduler:SchedulerMonthHeaderSettings Background = "LightGreen"
                                                           Height="200" />
               </scheduler:SchedulerAgendaView.MonthHeaderSettings>
           </scheduler:SchedulerAgendaView>
       </scheduler:SfScheduler.AgendaView>
    </scheduler:SfScheduler>
    this.scheduler.View = SchedulerView.Agenda;
    this.scheduler.AgendaView.DayHeaderSettings.Background = Brush.LightGreen;
    this.scheduler.AgendaView.DayHeaderSettings.Width = 100;
    this.scheduler.AgendaView.DayHeaderSettings.DayFormat = "MM, dddd";
    this.scheduler.AgendaView.WeekHeaderSettings.Background = Brush.LightGreen;
    this.scheduler.AgendaView.WeekHeaderSettings.Height = 200;
    this.scheduler.AgendaView.WeekHeaderSettings.DateFormat = "MM, ddd";
    this.scheduler.AgendaView.MonthHeaderSettings.Background = Brush.LightGreen;
    this.scheduler.AgendaView.MonthHeaderSettings.Height = 200;
    this.scheduler.AgendaView.MonthHeaderSettings.DateFormat = "MMM yyy";
    var appointments = new ObservableCollection<SchedulerAppointment>();
    for (int startdate = -30; startdate< 30; startdate++)
    {
       for (int i = 0; i< 1; i++)
       {
           for (int j = 0; j< 7; j++)
           {
              appointments.Add(new SchedulerAppointment()
              {
                    StartTime = DateTime.Now.Date.AddDays(startdate).AddHours(j),
                    EndTime = DateTime.Now.Date.AddDays(startdate).AddHours(j + 1),
                    Subject = j.ToString(),
              });
           }
        }
     }
    this.scheduler.AppointmentsSource = appointments;
    See Also
    Agenda
    AppointmentsSource

    AllowAppointmentDrag

    Gets or sets a value indicating whether the scheduler control allows appointments to be dragged or not on the view.

    Declaration
    public bool AllowAppointmentDrag { get; set; }
    Property Value
    Type Description
    System.Boolean

    true if appointments can be dragged, otherwise false.

    Examples

    The below examples shows, how to use the AllowAppointmentDrag of the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="Week"
                          AllowAppointmentDrag="False">
    </schedule:SfScheduler>
    this.Scheduler.AllowAppointmentDrag = false;

    AllowedViews

    Gets or sets the AllowedViews that will be displayed on the SfScheduler header for quick navigation.

    Declaration
    public SchedulerViews AllowedViews { get; set; }
    Property Value
    Type Description
    SchedulerViews

    The default value of allowed views is Default.

    Remarks

    The View will be restricted based on the AllowedViews. For example, the AllowedViews given as Day, Week, WorkWeek, and if the View given as Month, this will be reset to AllowedViews first value.

    Examples

    The below examples shows, how to use the built-in allowedviews of SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          AllowedViews="Day,Week,WorkWeek,Month">
     </schedule:SfScheduler>
    this.Scheduler.AllowedViews = SchedulerViews.Day | SchedulerViews.Week | SchedulerViews.WorkWeek | SchedulerViews.Month;
    See Also
    Default
    Day
    Week
    WorkWeek
    Month
    TimelineDay
    TimelineWeek
    TimelineWorkWeek
    TimelineMonth

    AllowViewNavigation

    Gets or sets a value indicating whether the current view should navigate to the respective day or timeline day view on clicking a month cell or a date in the view header of the following views: week, work week, month, timeline week, timeline work week and timeline month views.

    Declaration
    public bool AllowViewNavigation { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value of AllowViewNavigation is false.

    Remarks

    AllowViewNavigation is not applicable in day and timeline day views. If the day or timeline day views are not added in AllowedViews, the view will not navigate.

    Examples

    The below examples shows, how to use the AllowViewNavigation property in the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          AllowViewNavigation="true">
     </schedule:SfScheduler>
    this.Scheduler.AllowViewNavigation = true;
    See Also
    AllowViewNavigation
    AllowedViews

    AppointmentBorderStyle

    Gets or sets the border style of the appointments, allowing customization of the border stroke, stroke thickness, and corner radius.

    Declaration
    public SchedulerAppointmentBorderStyle AppointmentBorderStyle { get; set; }
    Property Value
    Type
    SchedulerAppointmentBorderStyle
    Remarks

    It is not applicable to the desktop UI of the Agenda view.

    Examples

    The example below shows how to set the AppointmentBorderStyle in the SfScheduler.

    var appointmentBorderStyle = new SchedulerAppointmentBorderStyle()
    {
        StrokeThickness = 10.0,
        Stroke = Colors.Red,
        CornerRadius = 2.0,
    };
    this.Scheduler.AppointmentBorderStyle = appointmentBorderStyle;
    See Also
    AppointmentsSource

    AppointmentMapping

    Gets or sets the custom object configuration mapping information to SchedulerAppointment.

    Declaration
    public SchedulerAppointmentMapping AppointmentMapping { get; set; }
    Property Value
    Type
    SchedulerAppointmentMapping
    Remarks

    The custom appointment class should contain event StartTime and EndTime fields as mandatory.

    Examples

    The below examples shows, how to use to configure the custom appointment.

    • XAML
    • C#
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="Week" >
         <schedule:SfScheduler.AppointmentMapping>
             <schedule:SchedulerAppointmentMapping
                    Subject = "EventName"
                    StartTime="From"
                    EndTime="To"
                    Background="Background"
            </schedule:SchedulerAppointmentMapping>
         </schedule:SfScheduler.AppointmentMapping>
    </schedule:SfScheduler>
    public class Meeting
    {
        public string EventName { get; set; }
        public DateTime From { get; set; }
        public DateTime To { get; set; }
        public Brush Background { get; set; }
    }
     SchedulerAppointmentMapping dataMapping = new SchedulerAppointmentMapping();
     dataMapping.Subject = "EventName";
     dataMapping.StartTime = "From";
     dataMapping.EndTime = "To";
     dataMapping.Background = "Background";
     this.Scheduler.AppointmentMapping = dataMapping;
    See Also
    SchedulerAppointment
    SchedulerAppointmentMapping

    AppointmentsSource

    Gets or sets the value which used to set the appointment collection to the scheduler.

    Declaration
    public object AppointmentsSource { get; set; }
    Property Value
    Type
    System.Object
    Remarks

    The appointments source AppointmentsSource can take System.Object collection of both SchedulerAppointment or custom class. When custom class collection is provided, it is necessary to map the custom class with schedule using the SchedulerAppointmentMapping.

    Examples

    The below examples shows, how to set the appointment collection to the AppointmentsSource in the SfScheduler.

    • XAML
    • C#
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          AppointmentsSource="{Binding Appointments}">
           <schedule:SfScheduler.BindingContext>
                <local:SchedulerViewModel/>
          </schedule:SfScheduler.BindingContext>
     </schedule:SfScheduler>
    public class SchedulerViewModel
    {
       public ObservableCollection<SchedulerAppointment> Appointments { get; set; } = new ObservableCollection<SchedulerAppointment>();
       public SchedulerViewModel()
       {
           Appointments.Add(new SchedulerAppointment()
           {
              Subject = "meeting",
              StartTime = DateTime.Now,
              EndTime = DateTime.Now.AddHours(1),
              StartTimeZone = TimeZoneInfo.FindSystemTimeZoneById("India Standard Time"),
              EndTimeZone = TimeZoneInfo.FindSystemTimeZoneById("India Standard Time")
           });
       }
    }
    var appointments = new ObservableCollection<SchedulerAppointment>();
    appointments.Add(new SchedulerAppointment()
    {
       Subject = "meeting",
       StartTime = DateTime.Now,
       EndTime = DateTime.Now.AddHours(1),
       StartTimeZone = TimeZoneInfo.FindSystemTimeZoneById("India Standard Time"),
       EndTimeZone = TimeZoneInfo.FindSystemTimeZoneById("India Standard Time")
    });
    this.Scheduler.AppointmentsSource = appointments;
    See Also
    SchedulerAppointment
    SchedulerAppointmentMapping

    AppointmentTextStyle

    Gets or sets the style of appointment text, that used to customize the text color, font, font size, font family and font attributes.

    Declaration
    public SchedulerTextStyle AppointmentTextStyle { get; set; }
    Property Value
    Type
    SchedulerTextStyle
    Remarks

    If the TextColor value is set , then appointment foreground will be set to TextColor value. If the TextColor value is null, and if the TextColor value is set then the TextColor value will be set to appointment text color ; otherwise, the appointment Background luminosity will be used to determine the default appointment TextColor value. If the background color of the appointment is light, the appointment text color will be black; otherwise, the text color will be white.

    It will be applicable to all View.
    Examples

    The below examples shows, how to use the AppointmentTextStyle to the SfScheduler.

    var appointments = new ObservableCollection<SchedulerAppointment>();
    appointments.Add(new SchedulerAppointment()
    {
      Subject = "meeting",
      StartTime = DateTime.Now,
      EndTime = DateTime.Now.AddHours(1),
    });
    this.Scheduler.AppointmentsSource = appointments;
    var appointmentTextStyle = new SchedulerTextStyle()
    {
      TextColor = Colors.Red,
      FontSize = 12,
    };
    this.Scheduler.AppointmentTextStyle = appointmentTextStyle;
    See Also
    SchedulerAppointment
    SchedulerAppointmentMapping

    BusyIndicatorTemplate

    Gets or sets the Microsoft.Maui.Controls.DataTemplate which will be loaded as a AppointmentsSource. If it is null, the default load more view will be loaded.

    Declaration
    public DataTemplate BusyIndicatorTemplate { get; set; }
    Property Value
    Type
    Microsoft.Maui.Controls.DataTemplate
    Remarks

    The scheduler view will be set as binding context.

    Examples

    The below examples shows, how to use the BusyIndicatorTemplate of the SfScheduler.

    <scheduler:SfScheduler x:Name="Scheduler"
                           View="Week"
                           ShowBusyIndicator="True">
      <scheduler:SfScheduler.BusyIndicatorTemplate>
          <DataTemplate>
              <Grid Background = "LightGray" Opacity="0.2">
                  <Label Text = "Loading..." HorizontalOptions="Center" VerticalOptions="Center" TextColor="Blue"/>
              </Grid>
          </DataTemplate>
      </scheduler:SfScheduler.BusyIndicatorTemplate>
    </scheduler:SfScheduler>

    CalendarType

    Gets or sets the calendar system to use.

    Declaration
    public CalendarType CalendarType { get; set; }
    Property Value
    Type Description
    CalendarType

    The default value is Gregorian.

    Remarks

    FlowDirection will be updated based on the CalendarType and if you want to override this behavior, set FlowDirection after CalendarType

    If calendar type is specified other than Gregorian, all the DateTime values such as Appointment Start and End time, SpecialTimeRegion Start and End time, SelectableDayPredicate, SelectedDate and DisplayDate can be given in two ways.

    1. DateTime instance without specifying calendar type. Scheduler will handle the DateTime value for the specified calendar type.
    2. When a DateTime instance has a calendar type, the Scheduler handles it directly.

    All calendar types are supported except Lunar type calendars.

    Examples

    The below examples shows, how to use the calendar types in SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          CalendarType="Hebrew">
     </schedule:SfScheduler>
    this.Scheduler.CalendarType = CalendarType.Hebrew;

    CellBorderBrush

    Gets or sets the color that describes the cell border color value.

    Declaration
    public Brush CellBorderBrush { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.Brush

    The default value of CellBorderBrush is Microsoft.Maui.Controls.Brush.LightGray.

    Remarks

    It will be applicable in all View.

    Examples

    The below examples shows, how to set the CellBorderBrush to the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          CellBorderBrush="Blue">
     </schedule:SfScheduler>
     this.Scheduler.CellBorderBrush = Brush.Blue;

    CellSelectionView

    Gets or sets the cell selection settings for customizing the appearance of the cell selection view in the scheduler.

    Declaration
    public SchedulerCellSelectionView CellSelectionView { get; set; }
    Property Value
    Type
    SchedulerCellSelectionView
    Remarks

    The CellSelectionView property allows you to configure various visual aspects of the selection view, including stroke color, fill color, or using a custom view for a personalized user interface.

    Examples

    This example demonstrates how to set the CellSelectionView property:

    • XAML
    • C#
    <scheduler:SfScheduler x:Name="Scheduler">
        <scheduler:SfScheduler.CellSelectionView>
            <scheduler:SchedulerCellSelectionView Stroke="Blue" Background="Orange"
                CornerRadius="5" StrokeWidth="5"/>
        </scheduler:SfScheduler.CellSelectionView>
    </scheduler:SfScheduler>
    this.Scheduler.CellSelectionView.Background = Brush.Red;
    this.Scheduler.CellSelectionView.Stroke = Brush.Blue;
    this.Scheduler.CellSelectionView.StrokeWidth = 5;
    this.Scheduler.CellSelectionView.CornerRadius = 5

    DaysView

    Gets or sets the properties which allows to customize the day, week and work week view of the SfScheduler.

    Declaration
    public SchedulerDaysView DaysView { get; set; }
    Property Value
    Type Description
    SchedulerDaysView

    The properties settings used to customize the day, week and work week views.

    Examples

    The below examples shows, how to use the DaysView settings of the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="Week">
    <schedule:SfScheduler.DaysView>
    <schedule:SchedulerDaysView StartHour = "8"
                                        EndHour="15"
                                        TimeIntervalSize="100"
                                        TimeRulerSize="100"/>
    </schedule:SfScheduler.DaysView>
    </schedule:SfScheduler>
    this.Scheduler.View = SchedulerView.Week;
    this.Scheduler.DaysView.StartHour = 8;
    this.Scheduler.DaysView.EndHour = 15;
    this.Scheduler.DaysView.TimeIntervalSize = 100;
    this.Scheduler.DaysView.TimeRulerSize = 100;
    See Also
    Day
    Week
    WorkWeek

    DisabledDateBackground

    Gets or sets the background color for the disabled date, that used to customize the background color.

    Declaration
    public Brush DisabledDateBackground { get; set; }
    Property Value
    Type
    Microsoft.Maui.Controls.Brush
    Remarks

    It is not applicable for month cells and view header cells.

    Examples

    The below examples shows, how to set the DisabledDateBackground to the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          DisabledDateBackground="Blue">
     </schedule:SfScheduler>
    this.Scheduler.DisabledDateBackground = Brush.Blue;
    See Also
    SelectableDayPredicate
    DisabledDateTextStyle
    MinimumDateTime
    MaximumDateTime

    DisabledDateTextStyle

    Gets or sets the style of disabled date, that used to customize the text color, font, font size, font family and font attributes.

    Declaration
    public SchedulerTextStyle DisabledDateTextStyle { get; set; }
    Property Value
    Type
    SchedulerTextStyle
    Remarks

    It will be applicable to all View.

    Examples

    The below examples shows, how to use the DisabledDateTextStyle to the SfScheduler.

    var disabledDateTextStyle = new SchedulerTextStyle()
    {
       TextColor = Colors.Red,
       FontSize = 12,
    };
    this.Scheduler.DisabledDateTextStyle = disabledDateTextStyle;
    See Also
    SelectableDayPredicate
    DisabledDateBackground
    MinimumDateTime
    MaximumDateTime

    DisplayDate

    Gets or sets the display date to programmatically navigate the dates in the SfScheduler.

    Declaration
    public DateTime DisplayDate { get; set; }
    Property Value
    Type Description
    System.DateTime

    The Display date.

    Remarks

    The date navigation before the MinimumDateTime will be reset to the scheduler minimum date value and date navigation beyond the MaximumDateTime will be reset to the scheduler maximum date value.

    Examples

    The below examples shows, how to set the DisplayDate to the SfScheduler.

    • XAML
    • C#
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          DisplayDate="{Binding DisplayDate, Mode=TwoWay}">
        <schedule:SfScheduler.BindingContext>
              <local:SchedulerViewModel/>
        </schedule:SfScheduler.BindingContext>
     </schedule:SfScheduler>
    public class SchedulerViewModel
    {
       public DateTime DisplayDate { get; set; }
       public SchedulerViewModel()
       {
           DisplayDate = new DateTime(2021, 12, 01);
       }
    }
     this.Scheduler.DisplayDate = new DateTime(2021, 12, 01);
    See Also
    MinimumDateTime
    MaximumDateTime
    Forward()
    Backward()
    SelectedDate

    DoubleTappedCommand

    Gets or sets the System.Windows.Input.ICommand to invoke after the double tap action.

    Declaration
    public ICommand DoubleTappedCommand { get; set; }
    Property Value
    Type Description
    System.Windows.Input.ICommand

    The default value is null.

    Remarks

    The SchedulerDoubleTappedEventArgs passed as command parameter.

    Examples

    The following code demonstrates, how to use the SfScheduler's DoubleTappedCommand property.

    # [XAML](#tab/tabid-54)
    <Grid>
     <Grid.BindingContext>
        <local:SchedulerInteractionViewModel />
    </Grid.BindingContext>
    <scheduler:SfScheduler x:Name="Scheduler"
                           View="Week"
                           AllowedViews="Day,Week,WorkWeek,Month"
                           DoubleTappedCommand="{Binding SchedulerDoubleTappedCommand}">
    </scheduler:SfScheduler>
    </Grid>
    # [XAML](#tab/tabid-55)
    public class SchedulerInteractionViewModel
    {
    public ICommand SchedulerDoubleTappedCommand { get; set; }
    public SchedulerInteractionViewModel()
    {
       this.SchedulerDoubleTappedCommand = new Command<SchedulerDoubleTappedEventArgs>(ExecuteDoubleTapped, CanExecuteDoubleTapped);
    }
    private bool CanExecuteDoubleTapped(SchedulerDoubleTappedEventArgs arg)
    {
        return true;
    }
    private void ExecuteDoubleTapped(SchedulerDoubleTappedEventArgs obj)
    {
       var appointments = obj.Appointments;
       var selectedDate = obj.Date;
       var schedulerElement = obj.Element;
    }
    }
    See Also
    DoubleTapped

    DragDropSettings

    Gets or sets the drag and drop settings to customize the appointment position, dragging indicator style, navigation, and time indicator format.

    Declaration
    public DragDropSettings DragDropSettings { get; set; }
    Property Value
    Type
    DragDropSettings
    Examples

    The below examples shows, how to use the DragDropSettings of the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="Week">
       <schedule:SfScheduler.DragDropSettings>
           <schedule:DragDropSettings AllowNavigation = "False"
                                      AllowScroll="False"
                                      ShowTimeIndicator="False">
           </schedule:DragDropSettings>
       </schedule:SfScheduler.DragDropSettings>
    </schedule:SfScheduler>
     this.Scheduler.DragDropSettings = new DragDropSettings() { AllowNavigation = false, AllowScroll = false, ShowTimeIndicator = false };

    EnableReminder

    Gets or sets a value indicating whether that allows or disallows triggering the ReminderAlertOpening event to the Reminders.

    Declaration
    public bool EnableReminder { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false.

    Remarks

    EnableReminder should be true to trigger the ReminderAlertOpening event. The reminder alert will be created based on the Reminders. An appointment can have one or more reminders. The built-in reminder alert notification is not supported as framework restriction with .NET MAUI Framework. https://github.com/dotnet/maui/discussions/4216

    Examples

    This example shows how to create reminders for an appointment and enable reminder alerts in SfScheduler.

    # [C#](#tab/tabid-64)
    var scheduler = new SfScheduler();
    scheduler.EnableReminder = true;
    ObservableCollection<SchedulerAppointment> Appointments = new ObservableCollection<SchedulerAppointment>();
    public ObservableCollection<SchedulerReminder> Reminders = new ObservableCollection<SchedulerReminder>();
    SchedulerAppointment appointment = new SchedulerAppointment()
    {
    StartTime = DateTime.Now.AddMinutes(2),
    EndTime = DateTime.Now.AddHours(1),
    Subject = "Normal Appointment",
    Reminders = new ObservableCollection<SchedulerReminder>
    {
    new SchedulerReminder {TimeInterval = new TimeSpan (0,0,60)},
    }
    };
    Appointments.Add(appointment);
    Scheduler.AppointmentsSource = Appointments;

    FirstDayOfWeek

    Gets or sets the day to change the default first day of week in the SfScheduler.

    Declaration
    public DayOfWeek FirstDayOfWeek { get; set; }
    Property Value
    Type Description
    System.DayOfWeek

    The default value of first day of week is System.DayOfWeek.Sunday.

    Remarks

    This property will be applicable to Week, WorkWeek, Month TimelineWeek, TimelineWorkWeek and TimelineMonth views only.

    Examples

    The below examples shows, how to use the first day of week property in the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          FirstDayOfWeek="Thursday">
     </schedule:SfScheduler>
    this.Scheduler.FirstDayOfWeek = DayOfWeek.Thursday;

    HeaderView

    Gets or sets the properties which allows to customize the scheduler header of day, week and work week, month, timeline day, timeline week, timeline work week, and timeline month views of the SfScheduler.

    Declaration
    public SchedulerHeaderView HeaderView { get; set; }
    Property Value
    Type Description
    SchedulerHeaderView

    The default header height is 50.

    Remarks

    The properties settings used to customize the day, week and work week, month, timeline day, timeline week, timeline work week, and timeline month views.

    Examples

    The below examples shows, how to use the Header settings of the SfScheduler.

    this.Scheduler.View = SchedulerView.Day;
    var schedulerTextStyle = new SchedulerTextStyle()
    {
       TextColor = Colors.White,
    };
    var schedulerHeaderView = new SchedulerHeaderView()
    {
       Background = Brush.Red,
       Height = 100,
       TextStyle = schedulerTextStyle,
       TextFormat = "dd-mmm-yyyy"
    };
    this.Scheduler.HeaderView = schedulerHeaderView;
    See Also
    Day
    Week
    WorkWeek
    Month
    TimelineDay
    TimelineWeek
    TimelineWorkWeek
    TimelineMonth

    LongPressedCommand

    Gets or sets the System.Windows.Input.ICommand to invoke after the long press action.

    Declaration
    public ICommand LongPressedCommand { get; set; }
    Property Value
    Type Description
    System.Windows.Input.ICommand

    The default value is null.

    Remarks

    The SchedulerLongPressedEventArgs passed as command parameter.

    Examples

    The following code demonstrates, how to use the SfScheduler's LongPressedCommand property.

    # [XAML](#tab/tabid-56)
    <Grid>
     <Grid.BindingContext>
        <local:SchedulerInteractionViewModel />
    </Grid.BindingContext>
    <scheduler:SfScheduler x:Name="Scheduler"
                           View="Week"
                           AllowedViews="Day,Week,WorkWeek,Month"
                           LongPressedCommand="{Binding SchedulerLongPressedCommand}">
    </scheduler:SfScheduler>
     </Grid>
    # [XAML](#tab/tabid-57)
    public class SchedulerInteractionViewModel
    {
    public ICommand SchedulerLongPressedCommand { get; set; }
    public SchedulerInteractionViewModel()
    {
      this.SchedulerLongPressedCommand = new Command<SchedulerLongPressedEventArgs>(ExecuteLongPressed, CanExecuteLongPressed);
    }
    private bool CanExecuteLongPressed(SchedulerLongPressedEventArgs arg)
    {
        return true;
    }
    private void ExecuteLongPressed(SchedulerLongPressedEventArgs obj)
    {
        var appointments = obj.Appointments;
        var selectedDate = obj.Date;
        var schedulerElement = obj.Element;
    }
    }
    See Also
    LongPressed

    MaximumDateTime

    Gets or sets the maximun display date to restrict the visible dates in the SfScheduler.

    Declaration
    public DateTime MaximumDateTime { get; set; }
    Property Value
    Type Description
    System.DateTime

    The default value of MaximumDateTime is System.DateTime.MaxValue.

    Remarks

    The dates after maximum date will be disabled in UI and built-in navigation options are disabled to navigate beyond maximum date. Also, navigation and selection before minimum and beyond maximum dates using DisplayDate is not possible. The time slot selection after maximum dates and before minimum dates using the SelectedDate is not possible.

    Examples

    The below examples shows, how to set the MaximumDateTime to the SfScheduler.

    • XAML
    • C#
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          MaximumDateTime="{Binding MaximumDateTime, Mode=TwoWay}">
        <schedule:SfScheduler.BindingContext>
              <local:SchedulerViewModel/>
        </schedule:SfScheduler.BindingContext>
     </schedule:SfScheduler>
    public class SchedulerViewModel
    {
       public DateTime MaximumDateTime { get; set; }
       public SchedulerViewModel()
       {
           MaximumDateTime = new DateTime(2021, 12, 01);
       }
    }
     this.Scheduler.MaximumDateTime = new DateTime(2021, 12, 01);
    See Also
    MinimumDateTime
    DisplayDate
    Backward()
    Forward()
    SelectedDate
    StartHour
    EndHour

    MinimumDateTime

    Gets or sets the minimum display date to restrict the visible dates in the SfScheduler.

    Declaration
    public DateTime MinimumDateTime { get; set; }
    Property Value
    Type Description
    System.DateTime

    The default value of MinimumDateTime is System.DateTime.MinValue.

    Remarks

    The dates before minimum date will be disabled in UI and built-in navigation options are disabled to navigate beyond minimum date. Also, navigation and selection before minimum and beyond maximum dates using DisplayDate is not possible. The time slot selection before minimum dates and beyond maximum dates using the SelectedDate is not possible.

    Examples

    The below examples shows, how to set the MinimumDate to the SfScheduler.

    • XAML
    • C#
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          MinimumDateTime="{Binding MinimumDateTime, Mode=TwoWay}">
        <schedule:SfScheduler.BindingContext>
              <local:SchedulerViewModel/>
        </schedule:SfScheduler.BindingContext>
     </schedule:SfScheduler>
    public class SchedulerViewModel
    {
       public DateTime MinimumDateTime { get; set; }
       public SchedulerViewModel()
       {
           MinimumDateTime = new DateTime(2021, 11, 01);
       }
    }
     this.Scheduler.MinimumDateTime = new DateTime(2021, 11, 01);
    See Also
    MaximumDateTime
    DisplayDate
    Backward()
    Forward()
    SelectedDate
    StartHour
    EndHour

    MonthView

    Gets or sets properties which allows to customize the month view of the SfScheduler.

    Declaration
    public SchedulerMonthView MonthView { get; set; }
    Property Value
    Type Description
    SchedulerMonthView

    The properties settings used to customize the month view.

    Examples

    The below examples shows, how to use the MonthView settings of the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="Month">
       <schedule:SfScheduler.MonthView>
       <schedule:SchedulerMonthView AppointmentDisplayMode = "Indicator"
                                            AppointmentDisplayCount="3"
                                            NavigationDirection="Vertical"
                                            ShowLeadingAndTrailingDates="False"/>
        </schedule:SfScheduler.MonthView>
    </schedule:SfScheduler>
    this.Scheduler.View = SchedulerView.Month;
    this.Scheduler.MonthView.AppointmentDisplayMode = SchedulerMonthAppointmentDisplayMode.Indicator;
    this.Scheduler.MonthView.AppointmentDisplayCount = 3;
    this.Scheduler.MonthView.NavigationDirection = SchedulerMonthNavigationDirection.Vertical;
    this.Scheduler.MonthView.ShowLeadingAndTrailingDates = false;
    See Also
    Month

    QueryAppointmentsCommand

    Gets or sets the System.Windows.Input.ICommand to invoke after the visible dates changed or View changed to load the AppointmentsSource for the visible dates.

    Declaration
    public ICommand QueryAppointmentsCommand { get; set; }
    Property Value
    Type Description
    System.Windows.Input.ICommand

    The default value is null.

    Remarks

    The SchedulerQueryAppointmentsEventArgs passed as command parameter. This is used to load the appointments in on-demand for visible dates. Loading appointments in on-demand improves the loading performance when you have appointments ranging for multiple years. Once the ViewChanged event is raised, the query appointments command will be invoked. If an appointment has been added, deleted or updated within the visible dates, then the query appointments command will not be invoked. Since appointments were already loaded for that visible dates. The recurrence appointment should be added to the AppointmentsSource until the date of recurrence ends. If RecurrenceRule added with count or end date, you can use the GetDateTimeOccurrences(String, DateTime, Nullable<DateTime>, Nullable<DateTime>, Nullable<DateTime>, DayOfWeek) method to get recurrence date collection and compare recursive dates in the current visible dates then add recurrence appointment in AppointmentsSource if recursive dates in current visible dates. If RecurrenceRule added with no end date , then recurrence appointment should be added in the AppointmentsSource when all visible date changed from the recurrence start date. In the scheduler agenda view, the QueryAppointments command is used to load more appointments when the new month is loaded on view, whereas the new month appointments are added in scheduler AppointmentsSource. Other than agenda view, the scheduler AppointmentsSource can be reset for a new visible date range to improve appointment loading performance.

    Examples

    The following example describes to load appointments on demand using command

    # [XAML](#tab/tabid-50)
    <Grid>
     <Grid.BindingContext>
        <local:LoadOnDemandViewModel />
    </Grid.BindingContext>
    <scheduler:SfScheduler x:Name="Scheduler"
                           AppointmentsSource="{Binding Events}"
                           QueryAppointmentsCommand="{Binding QueryAppointmentsCommand}"
                           ShowBusyIndicator="{Binding ShowBusyIndicator}"
                           View="Week"
                           AllowedViews="Day,Week,WorkWeek,Month">
    </scheduler:SfScheduler>
     </Grid>
    # [XAML](#tab/tabid-51)
    public class LoadOnDemandViewModel : INotifyPropertyChanged
    {
       private ObservableCollection<SchedulerAppointment> events;
       private bool showBusyIndicator;
       public event PropertyChangedEventHandler PropertyChanged;
       public ICommand QueryAppointmentsCommand { get; set; }
       public ObservableCollection<SchedulerAppointment> Events
       {
           get { return events; }
           set
           {
               events = value;
               this.RaiseOnPropertyChanged(nameof(Events));
           }
       }
       public bool ShowBusyIndicator
       {
           get { return showBusyIndicator; }
           set
           {
               showBusyIndicator = value;
               this.RaiseOnPropertyChanged(nameof(ShowBusyIndicator));
           }
       }
       public LoadOnDemandViewModel()
       {
           this.QueryAppointmentsCommand = new Command<object>(LoadMoreAppointments, CanLoadMoreAppointments);
       }
       private void RaiseOnPropertyChanged(string propertyName)
       {
           this.PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
       }
       private bool CanLoadMoreAppointments(object obj)
       {
           return true;
       }
       private async void LoadMoreAppointments(object obj)
       {
           this.ShowBusyIndicator = true;
           await Task.Delay(2500);
           this.GenerateSchedulerAppointments((obj as SchedulerQueryAppointmentsEventArgs).VisibleDates);
           this.ShowBusyIndicator = false;
       }
       private void GenerateSchedulerAppointments(List<DateTime> dateRange)
       {
           this.Events.Add(new SchedulerAppointment
           {
               StartTime = dateRange[0].AddHours(10),
               EndTime = dateRange[0].AddHours(11),
               Subject = "Meeting",
           });
       }
    }
    See Also
    QueryAppointments

    ResourceView

    Gets or sets the properties which allows to customize the resource view.

    Declaration
    public SchedulerResourceView ResourceView { get; set; }
    Property Value
    Type
    SchedulerResourceView
    Remarks

    Scheduler supports displaying appointments in timeline views based on resources. Day, Week, WorkWeek, Month and Agenda views shows appointments without resource grouping.

    Examples

    The below examples shows, how to use the ResourceView of the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="TimelineMonth">
    <schedule:SfScheduler.ResourceView>
    <schedule:SchedulerResourceView MinimumRowHeight = "100"/>
    </schedule:SfScheduler.ResourceView>
    </schedule:SfScheduler>
    var schedulerResources = new ObservableCollection<SchedulerResource>()
    {
    new SchedulerResource() { Name = "Sophia", Background = Brush.Red, Id = "1000" },
    new SchedulerResource() { Name = "Zoey Addison", Background = Brush.Blue, Id = "1001" },
    new SchedulerResource() { Name = "James William", Background = Brush.Yellow, Id = "1002" },
    };
    this.Scheduler.ResourceView.Resources = schedulerResources;

    SelectableDayPredicate

    Gets or sets the view rendering to decide whether scheduler view date time should be selectable or not.

    Declaration
    public Func<DateTime, bool> SelectableDayPredicate { get; set; }
    Property Value
    Type
    System.Func<System.DateTime, System.Boolean>
    Remarks

    It will be applicable to all View.

    Examples

    The following code demonstrates, how to use the SfScheduler's SelectableDayPredicate function.

    this.Scheduler.SelectableDayPredicate = (date) =>
    {
       if (date.DayOfWeek == DayOfWeek.Sunday || date.DayOfWeek == DayOfWeek.Saturday)
       {
           return false;
       }
       return true;
     };
    See Also
    DisabledDateTextStyle
    DisabledDateBackground

    SelectedAppointmentBackground

    Gets or sets the color that describes the selection background for the scheduler appointments.

    Declaration
    public Brush SelectedAppointmentBackground { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.Brush

    The default value of SelectedAppointmentBackground is null.

    Remarks

    It will be applicable in all View.

    Examples

    The below examples shows, how to set the SelectedAppointmentBackground to the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          SelectedAppointmentBackground="Red">
    </schedule:SfScheduler>
    this.Scheduler.SelectedAppointmentBackground = Brush.Red;

    SelectedCellBackground

    Gets or sets the color that describes the selection background for the timeslot cell or month cell.

    Declaration
    public Brush SelectedCellBackground { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.Brush

    The default value of SelectedCellBackground is Microsoft.Maui.Controls.Brush.Blue.

    Remarks

    It will be applicable in all View. CellSelectionView Stroke Background Template

    Examples

    The below examples shows, how to set the SelectedCellBackground to the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          SelectedCellBackground="Orange">
     </schedule:SfScheduler>
    this.Scheduler.SelectedCellBackground = Brush.Orange;

    SelectedDate

    Gets or sets the Selected Date property for scheduler to select a particular date or time slot programmatically.

    Declaration
    public Nullable<DateTime> SelectedDate { get; set; }
    Property Value
    Type Description
    System.Nullable<System.DateTime>

    The selected date.

    Remarks

    The time slot selection before the MinimumDateTime and the time slot selection beyond the MaximumDateTime using the SelectedDate is not possible.

    Examples

    The below examples shows, how to select a particular date programmatically in the SfScheduler.

    • XAML
    • C#
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          SelectedDate="{Binding SelectedDate, Mode=TwoWay}">
        <schedule:SfScheduler.BindingContext>
              <local:SchedulerViewModel/>
        </schedule:SfScheduler.BindingContext>
     </schedule:SfScheduler>
    public class SchedulerViewModel
    {
       public DateTime SelectedDate { get; set; }
       public SchedulerViewModel()
       {
           SelectedDate = new DateTime(2021, 12, 01);
       }
    }
     this.Scheduler.SelectedDate = new DateTime(2021, 12, 01);
    See Also
    MinimumDateTime
    MaximumDateTime

    SelectionChangedCommand

    Gets or sets the System.Windows.Input.ICommand to invoke after the selection changed.

    Declaration
    public ICommand SelectionChangedCommand { get; set; }
    Property Value
    Type Description
    System.Windows.Input.ICommand

    The default value is null.

    Remarks

    The SchedulerSelectionChangedEventArgs passed as command parameter.

    Examples

    The following code demonstrates, how to use the SfScheduler's SelectionChangedCommand property.

    # [XAML](#tab/tabid-58)
    <Grid>
     <Grid.BindingContext>
        <local:SchedulerInteractionViewModel />
    </Grid.BindingContext>
    <scheduler:SfScheduler x:Name="Scheduler"
                           View="Week"
                           AllowedViews="Day,Week,WorkWeek,Month"
                           SelectionChangedCommand="{Binding SchedulerSelectionChangedCommand}">
    </scheduler:SfScheduler>
    </Grid>
    # [XAML](#tab/tabid-59)
    public class SchedulerInteractionViewModel
    {
      public ICommand SchedulerSelectionChangedCommand{ get; set; }
      public SchedulerInteractionViewModel()
      {
         this.SchedulerSelectionChangedCommand = new Command<SchedulerSelectionChangedEventArgs>(ExecuteSelectionChanged, CanExecuteSelectionChanged);
      }
      private bool CanExecuteSelectionChanged(SchedulerSelectionChangedEventArgs arg)
      {
          return true;
      }
      private void ExecuteSelectionChanged(SchedulerSelectionChangedEventArgs obj)
      {
         var newDateTime = obj.NewValue;
         var oldDateTime = obj.OldValue;
      }
    }
    See Also
    SelectionChanged

    ShowAllowedViews

    Gets or sets a value indicating whether to displays the AllowedViews on the header view of the SfScheduler.

    Declaration
    public bool ShowAllowedViews { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value of ShowAllowedViews is true.

    Remarks

    The ShowAllowedViews is applicable only when the AllowedViews is set.

    Examples

    The below examples shows, how to use the ShowAllowedViews property in the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler" AllowedViews="Day,Week,Month,Agenda,TimelineWeek"
                          ShowAllowedViews="false">
     </schedule:SfScheduler>
    this.Scheduler.AllowedViews = SchedulerViews.Day | SchedulerViews.Week | SchedulerViews.Month | SchedulerViews.Agenda | SchedulerViews.TimelineWeek;
    this.Scheduler.ShowAllowedViews = false;
    See Also
    AllowedViews

    ShowBusyIndicator

    Gets or sets a value indicating whether scheduler view is busy in loading appointments.

    Declaration
    public bool ShowBusyIndicator { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value is false.

    Remarks

    You might start and stop the animation before and after the appointments loaded QueryAppointments, and QueryAppointmentsCommand. If QueryAppointments, or QueryAppointmentsCommand is not raised and enabled show busy indicator, the busy indicator will be stoped once appointment has rendered.

    Examples

    The below examples shows, how to set the ShowBusyIndicator to the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          ShowBusyIndicator="True">
    </schedule:SfScheduler>
    this.Scheduler.ShowBusyIndicator = true;
    See Also
    QueryAppointments
    QueryAppointmentsCommand

    ShowDatePickerButton

    Gets or sets a value indicating whether to displays the calendar popUp arrow on the header view of the SfScheduler.

    Declaration
    public bool ShowDatePickerButton { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value of ShowDatePickerButton is false.

    Remarks

    The header view of SfScheduler will display the calendar popUp arrow which used to navigate to Calendar. The calendar popUp arrow will not shown in scheduler agenda view as scheduler date can be scrollable in agenda view.

    Examples

    The below examples shows, how to use the ShowNavigationArrows property in the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          ShowDatePickerButton="true">
     </schedule:SfScheduler>
    this.Scheduler.ShowDatePickerButton = true;

    ShowNavigationArrows

    Gets or sets a value indicating whether to displays the navigation arrows on the header view of the SfScheduler.

    Declaration
    public bool ShowNavigationArrows { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value of ShowNavigationArrows is true.

    Remarks

    The header view of SfScheduler will display the navigation arrows which used to navigate to the previous/next views through the navigation icon buttons. The navigation arrows will not shown in scheduler agenda view as scheduler date can be scrollable in agenda view.

    Examples

    The below examples shows, how to use the ShowNavigationArrows property in the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          ShowNavigationArrows="false">
     </schedule:SfScheduler>
    this.Scheduler.ShowNavigationArrows = false;
    See Also
    Forward()
    Backward()

    ShowTodayButton

    Gets or sets a value indicating whether to displays the today button on the header view of the SfScheduler.

    Declaration
    public bool ShowTodayButton { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value of ShowTodayButton is true.

    ShowWeekNumber

    Gets or sets a value indicating whether to displays the week number of the year in the SfScheduler.

    Declaration
    public bool ShowWeekNumber { get; set; }
    Property Value
    Type Description
    System.Boolean

    The default value of ShowWeekNumber is false.

    Remarks

    It is not applicable for the TimelineMonth. In the month view, it is displayed at the left side as a separate column. whereas in the week and work week view it is displayed beside the view header panel, and for day and timeline views it is displayed next to the header text in the header panel of the calendar.

    Examples

    The below examples shows, how to use the ShowWeekNumber property in the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          ShowWeekNumber="true">
     </schedule:SfScheduler>
    this.Scheduler.ShowWeekNumber = true;
    See Also
    WeekNumberStyle

    TappedCommand

    Gets or sets the value to invoke after tap action.

    Declaration
    public ICommand TappedCommand { get; set; }
    Property Value
    Type Description
    System.Windows.Input.ICommand

    The default value is null.

    Remarks

    The SchedulerTappedEventArgs passed as command parameter.

    Examples

    The following code demonstrates, how to use the SfScheduler's TappedCommand property.

    # [XAML](#tab/tabid-52)
    <Grid>
    <Grid.BindingContext>
        <local:SchedulerInteractionViewModel />
    </Grid.BindingContext>
    <scheduler:SfScheduler x:Name="Scheduler"
                           View="Week"
                           AllowedViews="Day,Week,WorkWeek,Month"
                           TappedCommand="{Binding SchedulerTappedCommand}">
    </scheduler:SfScheduler>
     </Grid>
    # [XAML](#tab/tabid-53)
    public class SchedulerInteractionViewModel
    {
    public ICommand SchedulerTappedCommand { get; set; }
    public SchedulerInteractionViewModel()
    {
        this.SchedulerTappedCommand = new Command<SchedulerTappedEventArgs>(ExecuteTapped, CanExecuteTapped);
    }
    private bool CanExecuteTapped(SchedulerTappedEventArgs arg)
    {
        return true;
    }
    private void ExecuteTapped(SchedulerTappedEventArgs obj)
    {
       var appointments = obj.Appointments;
       var selectedDate = obj.Date;
       var schedulerElement = obj.Element;
    }
    }
    See Also
    Tapped

    TimelineView

    Gets or sets the properties which allows to customize the timeline day, timeline week and timeline work week and timeline month views of the SfScheduler.

    Declaration
    public SchedulerTimelineView TimelineView { get; set; }
    Property Value
    Type Description
    SchedulerTimelineView

    The properties settings used to customize the timeline day, timeline week and timeline work week and timeline month views.

    Examples

    The below examples shows, how to use the TimelineView settings of the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="TimelineWeek">
    <schedule:SfScheduler.TimelineView>
       <schedule:SchedulerTimelineView StartHour = "8"
                                               EndHour="15"
                                               TimeIntervalSize="100"
                                               TimeRulerSize="100"/>
       </schedule:SfScheduler.TimelineView>
    </schedule:SfScheduler>
     this.Scheduler.View = SchedulerView.TimelineWeek;
     this.Scheduler.TimelineView.StartHour = 8;
     this.Scheduler.TimelineView.EndHour = 15;
     this.Scheduler.TimelineView.TimeIntervalSize = 100;
     this.Scheduler.TimelineView.TimeRulerSize = 100;
    See Also
    TimelineDay
    TimelineWeek
    TimelineWorkWeek
    TimelineMonth

    TimeZone

    Gets or sets the Time zone to customize the default time zone property of scheduler with particular time zone.

    Declaration
    public TimeZoneInfo TimeZone { get; set; }
    Property Value
    Type Description
    System.TimeZoneInfo

    The Time zone can be used in the following scenarios. Create an appointment in the different time zones. Display appointments based on the client’s time zone. Display appointments based on scheduler time zone. Display appointments at the same time everywhere regardless of the client’s time zone.

    Remarks

    If the recurring appointment is converted to another time zone, then the whole sequence will be re-calculated according to the new time zone information. If all-day appointment created, its start time and end time will be set to 12 AM and 12 AM by default, So time zone is not applicable for all-day appointments. The timeZone can be used for custom appointments by mapping the StartTimeZone and EndTimeZone custom properties of SchedulerAppointmentMapping.

    Examples

    The below examples shows, how to set the TimeZone to an appointments.

    var appointments = new ObservableCollection<SchedulerAppointment>();
    appointments.Add(new SchedulerAppointment()
    {
       Subject = "meeting",
       StartTime = DateTime.Now,
       EndTime = DateTime.Now.AddHours(1),
       StartTimeZone = TimeZoneInfo.FindSystemTimeZoneById("India Standard Time"),
       EndTimeZone = TimeZoneInfo.FindSystemTimeZoneById("India Standard Time")
    });
    this.Scheduler.AppointmentsSource = appointments;
    See Also
    SchedulerAppointment
    StartTimeZone
    EndTimeZone
    StartTime
    EndTime
    SchedulerAppointmentMapping

    TodayHighlightBrush

    Gets or sets the color that describes the today highlight color value.

    Declaration
    public Brush TodayHighlightBrush { get; set; }
    Property Value
    Type Description
    Microsoft.Maui.Controls.Brush

    The default value of TodayHighlightBrush is Microsoft.Maui.Controls.Brush.Blue.

    Remarks

    It allows to change the color that highlights the today cell in month view, view header of day/week/workweek, and in timeline view, the color will highlights the date text in the SfScheduler.

    Examples

    The below examples shows, how to set the TodayHighlightBrush to the SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          TodayHighlightBrush="Red">
     </schedule:SfScheduler>
    this.Scheduler.TodayHighlightBrush = Brush.Red;

    TodayTextStyle

    Gets or sets the style of today text, that used to customize the text color, font, font size, font family and font attributes.

    Declaration
    public SchedulerTextStyle TodayTextStyle { get; set; }
    Property Value
    Type Description
    SchedulerTextStyle

    The default value of TextColor is Microsoft.Maui.Graphics.Colors.White, FontSize is -1.0, FontFamily is null, FontAttributes is Microsoft.Maui.Controls.FontAttributes.None.

    Remarks

    The font size property will be applied from the text style properties of view headers. Eg: For today in view header, the font size will be applied from the DayTextStyle property and the text color will be applied only to today month cell, view header cell of day/week/workweek and in timeline views, the TodayHighlightBrush color will highlights the today's date text in the SfScheduler.

    Examples

    TodayHighlightBrush The below examples shows, how to use the TodayTextStyle to the SfScheduler.

    var todayTextStyle = new SchedulerTextStyle()
    {
        TextColor = Colors.Red,
        FontSize = 12,
    };
    this.Scheduler.TodayTextStyle = todayTextStyle;

    View

    Gets or sets the built in views such as day, week, work week, month, timeline day, timeline week, timeline work week, and timeline month views of the SfScheduler.

    Declaration
    public SchedulerView View { get; set; }
    Property Value
    Type Description
    SchedulerView

    The default value of view mode is Day. It allows users to easily select and navigate between all built-in views.

    Examples

    The below examples shows, how to use the built-in views of SfScheduler.

    • XAML
    • C#
    <schedule:SfScheduler x:Name="Scheduler"
                          View="Week">
     </schedule:SfScheduler>
    this.Scheduler.View = SchedulerView.Week;
    See Also
    Day
    Week
    WorkWeek
    Month
    TimelineDay
    TimelineWeek
    TimelineWorkWeek
    TimelineMonth

    ViewChangedCommand

    Gets or sets the System.Windows.Input.ICommand to invoke after the view changed or visible date changed.

    Declaration
    public ICommand ViewChangedCommand { get; set; }
    Property Value
    Type Description
    System.Windows.Input.ICommand

    The default value is null.

    Remarks

    The SchedulerViewChangedEventArgs passed as command parameter.

    Examples

    The following code demonstrates, how to use the SfScheduler's ViewChangedCommand property.

    # [XAML](#tab/tabid-60)
    <Grid>
    <Grid.BindingContext>
        <local:SchedulerInteractionViewModel />
    </Grid.BindingContext>
    <scheduler:SfScheduler x:Name="Scheduler"
                           View="Week"
                           AllowedViews="Day,Week,WorkWeek,Month"
                           ViewChangedCommand="{Binding SchedulerViewChangedCommand}">
    </scheduler:SfScheduler>
    </Grid>
    # [XAML](#tab/tabid-61)
    public class SchedulerInteractionViewModel
    {
    public ICommand SchedulerViewChangedCommand{ get; set; }
    public SchedulerInteractionViewModel()
    {
        this.SchedulerViewChangedCommand = new Command<SchedulerViewChangedEventArgs>(ExecuteViewChanged, CanExecuteViewChanged);
    }
    private bool CanExecuteViewChanged(SchedulerViewChangedEventArgs arg)
    {
       return true;
    }
    private void ExecuteViewChanged(SchedulerViewChangedEventArgs obj)
    {
       var oldVisibleDates = obj.OldVisibleDates;
       var newVisibleDates = obj.NewVisibleDates;
       var oldSchedulerView = obj.OldView;
       var newSchedulerView = obj.NewView;
    }
    }
    See Also
    ViewChanged

    WeekNumberStyle

    Gets or sets the style of the week number, that used to customize the background, text color, font, font size, font family and font attributes.

    Declaration
    public SchedulerWeekNumberStyle WeekNumberStyle { get; set; }
    Property Value
    Type
    SchedulerWeekNumberStyle
    Remarks

    It is not applicable for the TimelineMonth and it is applied only to when the ShowWeekNumber is enabled.

    Examples

    The below examples shows, how to set the WeekNumberStyle in the SfScheduler.

    var schedulerTextStyle = new SchedulerTextStyle()
    {
        TextColor = Colors.Red,
        FontSize = 14
    };
    var schedulerWeekNumberStyle = new SchedulerWeekNumberStyle()
    {
        Background = Brush.LightGreen,
        TextStyle = schedulerTextStyle
    };
    this.Scheduler.WeekNumberStyle = schedulerWeekNumberStyle;
    See Also
    ShowWeekNumber

    Methods

    Backward()

    Move to previous view which displays previous view dates.

    Declaration
    public void Backward()
    Remarks

    This method is not applicable for scheduler agenda view.

    Examples

    The following code demonstrates, how to use the SfScheduler's backward method.

    this.button.Clicked += this.OnButtonClicked;
    private void OnButtonClicked(object sender, EventArgs e)
    {
       this.Scheduler.Backward();
    }

    Forward()

    Move to next view which displays next view dates.

    Declaration
    public void Forward()
    Remarks

    This method is not applicable for scheduler agenda view.

    Examples

    The following code demonstrates, how to use the SfScheduler's forward method.

    this.button.Clicked += this.OnButtonClicked;
    private void OnButtonClicked(object sender, EventArgs e)
    {
      this.Scheduler.Forward();
    }

    OnBindingContextChanged()

    Invoked whenever the binding context of the value changed.

    Declaration
    protected override void OnBindingContextChanged()

    OnHandlerChanged()

    Declaration
    protected override void OnHandlerChanged()

    ResumeAppointmentViewUpdate()

    Resume the appointment view rendering once the collection is updated to improve appointment rendering performance.

    Declaration
    public void ResumeAppointmentViewUpdate()

    SuspendAppointmentViewUpdate()

    Suspends the appointment rendering when the appointment collection changes until the ResumeAppointmentViewUpdate() method is called. This prevents delays in the scheduler appointment rendering when updating each collection change.

    Declaration
    public void SuspendAppointmentViewUpdate()

    Events

    AppointmentDragOver

    Occurs when the user is dragging an appointment.

    Declaration
    public event EventHandler<AppointmentDragOverEventArgs> AppointmentDragOver
    Event Type
    Type
    System.EventHandler<AppointmentDragOverEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's appointment dragover event.

    this.Scheduler.AppointmentDragOver += this.OnSchedulerAppointmentDragOver;
    private void OnSchedulerAppointmentDragOver(object? sender, AppointmentDragOverEventArgs e)
    {
       var appointment = e.Appointment;
       var dragTime = e.DragTime;
       var resource = e.DragResource;
    }
    See Also
    AllowAppointmentDrag
    DragDropSettings
    AppointmentDragStarting
    AppointmentDrop

    AppointmentDragStarting

    Occurs when the user starts dragging an appointment.

    Declaration
    public event EventHandler<AppointmentDragStartingEventArgs> AppointmentDragStarting
    Event Type
    Type
    System.EventHandler<AppointmentDragStartingEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's appointment drag starting event.

    this.Scheduler.AppointmentDragStarting += this.OnSchedulerAppointmentDragStarting;
    private void OnSchedulerAppointmentDragStarting(object? sender, AppointmentDragStartingEventArgs e)
    {
       var appointment = e.Appointment;
       var resource = e.Resource;
    }
    See Also
    AllowAppointmentDrag
    DragDropSettings
    AppointmentDragOver
    AppointmentDrop

    AppointmentDrop

    Occurs when the user drops an appointment.

    Declaration
    public event EventHandler<AppointmentDropEventArgs> AppointmentDrop
    Event Type
    Type
    System.EventHandler<AppointmentDropEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's appointment drop event.

    this.Scheduler.AppointmentDrop += this.OnSchedulerAppointmentDrop;
    private void OnSchedulerAppointmentDrop(object? sender, AppointmentDropEventArgs e)
    {
       var appointment = e.Appointment;
       var dropTime = e.DropTime;
       var targetResource = e.TargetResource;
    }
    See Also
    AllowAppointmentDrag
    DragDropSettings
    AppointmentDragStarting
    AppointmentDragOver

    DoubleTapped

    Occurs after the tap interaction on Scheduler.

    Declaration
    public event EventHandler<SchedulerDoubleTappedEventArgs> DoubleTapped
    Event Type
    Type
    System.EventHandler<SchedulerDoubleTappedEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's double tapped event.

    this.Scheduler.DoubleTapped += this.OnSchedulerDoubleTapped;
    private void OnSchedulerDoubleTapped(object sender, SchedulerDoubleTappedEventArgs e)
    {
      var appointments = e.Appointments;
      var selectedDate = e.Date;
      var schedulerElement = e.Element;
    }

    LongPressed

    Occurs after the tap interaction on Scheduler.

    Declaration
    public event EventHandler<SchedulerLongPressedEventArgs> LongPressed
    Event Type
    Type
    System.EventHandler<SchedulerLongPressedEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's long pressed event.

    this.Scheduler.LongPressed += this.OnSchedulerLongPressed;
    private void OnSchedulerLongPressed(object sender, SchedulerLongPressedEventArgs e)
    {
       var appointments = e.Appointments;
       var selectedDate = e.Date;
       var schedulerElement = e.Element;
    }

    QueryAppointments

    Occurs after the visible dates changed or View changed. The AppointmentsSource for the visible dates can be loaded in on-demand using this event.

    Declaration
    public event EventHandler<SchedulerQueryAppointmentsEventArgs> QueryAppointments
    Event Type
    Type
    System.EventHandler<SchedulerQueryAppointmentsEventArgs>
    Remarks

    The SchedulerQueryAppointmentsEventArgs passed as command parameter. The QueryAppointments is used to load the appointments in on-demand for visible dates. Loading appointments in on-demand improves the loading performance when you have appointments ranging for multiple years. Once the ViewChanged event is raised, the QueryAppointments will be invoked. If an appointment has been added, deleted or updated within the visible dates, then the QueryAppointments will not be invoked. Since appointments were already loaded for that visible dates. The recurrence appointment should be added to the AppointmentsSource until the date of recurrence ends. If RecurrenceRule added with count or end date, you can use the GetDateTimeOccurrences(String, DateTime, Nullable<DateTime>, Nullable<DateTime>, Nullable<DateTime>, DayOfWeek) method to get recurrence date collection and compare recursive dates in the current visible dates then add recurrence appointment in AppointmentsSource if recursive dates in current visible dates. If RecurrenceRule added with no end date , then recurrence appointment should be added in the AppointmentsSource when all visible date changed from the recurrence start date. In the scheduler agenda view, the QueryAppointments event is used to load more appointments when the new month is loaded on view, whereas the new month appointments are added in scheduler AppointmentsSource. Other than agenda view, the scheduler AppointmentsSource can be reset for a new visible date range to improve appointment loading performance.

    Examples

    The following example describes to load appointments on demand using the QueryAppointments event.

    this.scheduler.QueryAppointments += OnSchedulerQueryAppointments;
    

    private async void OnSchedulerQueryAppointments(object sender, SchedulerQueryAppointmentsEventArgs e) { this.scheduler.ShowBusyIndicator = true; await Task.Delay(1000); this.scheduler.AppointmentsSource = this.GenerateSchedulerAppointments(e.VisibleDates); this.scheduler.ShowBusyIndicator = false; } private ObservableCollection<SchedulerAppointment> GenerateSchedulerAppointments(List<DateTime> dateRange) { var appointment = new ObservableCollection<SchedulerAppointment>(); appointment.Add(new SchedulerAppointment { StartTime = dateRange[0].AddHours(10), EndTime = dateRange[0].AddHours(11), Subject = "Meeting", }); return appointment; }

    See Also
    QueryAppointmentsCommand

    ReminderAlertOpening

    Occurs to remind the appointment for the TimeBeforeStart mentioned in Reminders.

    Declaration
    public event EventHandler<ReminderAlertOpeningEventArgs> ReminderAlertOpening
    Event Type
    Type
    System.EventHandler<ReminderAlertOpeningEventArgs>
    Remarks

    EnableReminder must be true to enable the appointment reminders.

    Examples

    The following example describes how to listen reminder alert opening using ReminderAlertOpening event.

    var scheduler = new SfScheduler();
    scheduler.EnableReminder = true;
    ObservableCollection<SchedulerAppointment> Appointments = new ObservableCollection<SchedulerAppointment>();
    SchedulerAppointment appointment = new SchedulerAppointment()
    {
    StartTime = DateTime.Now.AddMinutes(2),
    EndTime = DateTime.Now.AddHours(1),
    Subject = "Normal Appointment",
    Reminders = new ObservableCollection<SchedulerReminder>
    {
    new SchedulerReminder {TimeInterval = new TimeSpan (0,0,60)},
    }
    };
    Appointments.Add(appointment);
    Scheduler.AppointmentsSource = Appointments;
    this.Scheduler.ReminderAlertOpening += OnSchedulerReminderAlertOpening;
    private void OnSchedulerReminderAlertOpening (object sender, ReminderAlertOpeningEventArgs e)
    {
    e.Reminders[0]. IsDismissed = true;
    }
    }
    See Also
    EnableReminder
    ReminderAlertOpeningEventArgs
    SchedulerReminder
    TimeBeforeStart

    SelectionChanged

    Occurs after the selection is changed in Scheduler.

    Declaration
    public event EventHandler<SchedulerSelectionChangedEventArgs> SelectionChanged
    Event Type
    Type
    System.EventHandler<SchedulerSelectionChangedEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's selection changed event.

    this.Scheduler.SelectionChanged += this.OnSchedulerSelectionChanged;
    private void OnSchedulerSelectionChanged(object sender, SchedulerSelectionChangedEventArgs e)
    {
       var oldDateTime = e.OldValue;
       var newdateTime = e.NewValue;
    }

    Tapped

    Occurs after the tap interaction on Scheduler.

    Declaration
    public event EventHandler<SchedulerTappedEventArgs> Tapped
    Event Type
    Type
    System.EventHandler<SchedulerTappedEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's tapped event.

    this.Scheduler.Tapped += this.OnSchedulerTapped;
    private void OnSchedulerTapped(object sender, SchedulerTappedEventArgs e)
    {
      var appointments = e.Appointments;
      var selectedDate = e.Date;
      var schedulerElement = e.Element;
    }

    ViewChanged

    Occurs whenever the scheduler view or visible date changed.

    Declaration
    public event EventHandler<SchedulerViewChangedEventArgs> ViewChanged
    Event Type
    Type
    System.EventHandler<SchedulerViewChangedEventArgs>
    Examples

    The following code demonstrates, how to use the SfScheduler's view changed event.

    this.Scheduler.ViewChanged += this.OnSchedulerViewChanged;
    private void OnSchedulerViewChanged(object sender, SchedulerViewChangedEventArgs e)
    {
      var oldVisibleDates = e.OldVisibleDates;
      var newVisibleDates = e.NewVisibleDates;
      var oldSchedulerView = e.OldView;
      var newSchedulerView = e.NewView;
    }

    Implements

    Microsoft.Maui.IContentView
    Microsoft.Maui.IView
    Microsoft.Maui.IElement
    Microsoft.Maui.ITransform
    Microsoft.Maui.IPadding
    Microsoft.Maui.ICrossPlatformLayout
    Back to top Generated by DocFX
    Copyright © 2001 - 2025 Syncfusion Inc. All Rights Reserved