Implementing .NET MAUI Calendar (SfCalendar)
A comprehensive skill for implementing and customizing the Syncfusion .NET MAUI Calendar control. The SfCalendar provides powerful date selection capabilities with multiple view modes, extensive customization options, and flexible date restrictions.
When to Use This Skill
Use this skill when you need to:
- Implement a calendar control in .NET MAUI applications
- Enable date selection (single date, multiple dates, or date ranges)
- Display calendar views (Month, Year, Decade, Century)
- Restrict date selection with min/max dates or custom validation
- Customize calendar appearance (backgrounds, text styles)
- Handle calendar events (selection changes, view changes, taps)
- Configure week numbers, first day of week, or trailing/leading dates
- Implement localization or RTL support for calendars
- Add special date highlighting or weekend styling
- Navigate programmatically between dates or views
Component Overview
SfCalendar is a feature-rich calendar control that allows users to:
- Select single dates, multiple dates, or date ranges
- Navigate through Month, Year, Decade, and Century views
- Restrict dates using MinimumDate, MaximumDate, EnablePastDates, or SelectableDayPredicate
- Customize every aspect of the calendar's appearance
- Respond to user interactions through comprehensive events
Key Capabilities:
- 4 calendar views for flexible navigation
- 3 selection modes (Single, Multiple, Range)
- Comprehensive date restriction options
- Full customization (dates, today, trailing/leading)
- Rich event system for user interactions
- Localization and globalization support
- RTL (Right-to-Left) language support
Documentation and Navigation Guide
Getting Started
📄 Read: references/getting-started.md
- Installation and NuGet package setup (Syncfusion.Maui.Calendar)
- Handler registration in MauiProgram.cs
- Basic SfCalendar initialization in XAML and C#
- First day of week customization
- Corner radius configuration
Calendar Views
📄 Read: references/calendar-views.md
- Month view (default, most common)
- Year view for month selection
- Decade view for year selection
- Century view for decade selection
- NumberOfVisibleWeeks property
- Week number display (ShowWeekNumber)
- View navigation and switching
Date Selection
📄 Read: references/date-selection.md
- Single selection mode (one date at a time)
- Multiple selection mode (select multiple dates)
- Range selection mode (select date ranges)
- EnableSwipeSelection for range selection
- RangeSelectionDirection (Forward, Backward, Both, None)
- Programmatic selection with SelectedDate/SelectedDates/SelectedRange
- Selection behavior in different views
Date Restrictions
📄 Read: references/date-restrictions.md
- MinimumDate property (restrict backward navigation)
- MaximumDate property (restrict forward navigation)
- EnablePastDates property (disable dates before today)
- SelectableDayPredicate (custom date validation logic)
- Disabling weekends or specific dates
- Date validation patterns
Date Navigation
📄 Read: references/date-navigation.md
- DisplayDate property for programmatic navigation
- Programmatic view switching
- AllowViewNavigation property
- NavigateToAdjacentMonth (leading/trailing date navigation)
- Swipe gestures for month/year navigation
- Header tap navigation between views
Calendar Modes and Display Options
📄 Read: references/calendar-modes.md
- Default mode (inline display)
- Dialog mode (centered popup)
- RelativeDialog mode (positioned popup)
- CalendarRelativePosition enum (AlignTop, AlignBottom, AlignToLeftOf, AlignToRightOf, etc.)
- IsOpen property for programmatic control
- PopupWidth and PopupHeight customization
- Date picker patterns
Customization and Styling
📄 Read: references/customizations.md
- Month cell customization (dates, today, trailing/leading)
- Text styles (TextStyle, TodayTextStyle, DisabledDatesTextStyle)
- Background colors for all cell states
- Weekend date styling
- Special date highlighting with icons (Dot, Heart, Diamond, Star, Bell)
- Year, Decade, and Century view customization
- CalendarTextStyle properties (TextColor, FontSize, FontFamily)
Events and Interactions
📄 Read: references/events.md
- ViewChanged event (view/date range changes)
- SelectionChanged event (date selection changes)
- Tapped event (single tap on dates)
- DoubleTapped event (double tap on dates)
- LongPressed event (long press on dates)
- Event arguments and data
- Event handling patterns
Headers and Footers
📄 Read: references/headers-footers.md
- HeaderView customization (height, background, text style)
- Header text format customization
- ShowNavigationArrows property
- HeaderTemplate for custom header UI
- FooterView customization
- Custom footer templates
Localization and Advanced Features
📄 Read: references/localization-advanced.md
- Globalization and localization setup
- CurrentUICulture configuration
- Resource file creation for multiple languages
- RTL (Right-to-Left) support
- CalendarIdentifier (Gregorian, Hijri, etc.)
- Calendar modes
- Liquid glass effect
- Advanced visual customization
1---2name: syncfusion-maui-calendar3description: Implements and customize Syncfusion .NET MAUI Calendar (SfCalendar) control. Use when implementing calendar functionality, date selection (single, multiple, range), or calendar views (month, year, decade, century). Covers date restrictions (min/max dates, EnablePastDates, SelectableDayPredicate), calendar customization, events (ViewChanged, SelectionChanged, Tapped), and header/footer customization.4---5
6# Implementing .NET MAUI Calendar (SfCalendar)
7
8A comprehensive skill for implementing and customizing the Syncfusion .NET MAUI Calendar control. The SfCalendar provides powerful date selection capabilities with multiple view modes, extensive customization options, and flexible date restrictions.
9
10## When to Use This Skill
11
12Use this skill when you need to:
13- Implement a calendar control in .NET MAUI applications
14- Enable date selection (single date, multiple dates, or date ranges)
15- Display calendar views (Month, Year, Decade, Century)
16- Restrict date selection with min/max dates or custom validation
17- Customize calendar appearance (backgrounds, text styles)
18- Handle calendar events (selection changes, view changes, taps)
19- Configure week numbers, first day of week, or trailing/leading dates
20- Implement localization or RTL support for calendars
21- Add special date highlighting or weekend styling
22- Navigate programmatically between dates or views
23
24## Component Overview
25
26**SfCalendar** is a feature-rich calendar control that allows users to:
27- Select single dates, multiple dates, or date ranges
28- Navigate through Month, Year, Decade, and Century views
29- Restrict dates using MinimumDate, MaximumDate, EnablePastDates, or SelectableDayPredicate
30- Customize every aspect of the calendar's appearance
31- Respond to user interactions through comprehensive events
32
33**Key Capabilities:**
34- 4 calendar views for flexible navigation
35- 3 selection modes (Single, Multiple, Range)
36- Comprehensive date restriction options
37- Full customization (dates, today, trailing/leading)
38- Rich event system for user interactions
39- Localization and globalization support
40- RTL (Right-to-Left) language support
41
42## Documentation and Navigation Guide
43
44### Getting Started
45📄 **Read:** [references/getting-started.md](references/getting-started.md)
46- Installation and NuGet package setup (Syncfusion.Maui.Calendar)
47- Handler registration in MauiProgram.cs
48- Basic SfCalendar initialization in XAML and C#
49- First day of week customization
50- Corner radius configuration
51
52### Calendar Views
53📄 **Read:** [references/calendar-views.md](references/calendar-views.md)
54- Month view (default, most common)
55- Year view for month selection
56- Decade view for year selection
57- Century view for decade selection
58- NumberOfVisibleWeeks property
59- Week number display (ShowWeekNumber)
60- View navigation and switching
61
62### Date Selection
63📄 **Read:** [references/date-selection.md](references/date-selection.md)
64- Single selection mode (one date at a time)
65- Multiple selection mode (select multiple dates)
66- Range selection mode (select date ranges)
67- EnableSwipeSelection for range selection
68- RangeSelectionDirection (Forward, Backward, Both, None)
69- Programmatic selection with SelectedDate/SelectedDates/SelectedRange
70- Selection behavior in different views
71
72### Date Restrictions
73📄 **Read:** [references/date-restrictions.md](references/date-restrictions.md)
74- MinimumDate property (restrict backward navigation)
75- MaximumDate property (restrict forward navigation)
76- EnablePastDates property (disable dates before today)
77- SelectableDayPredicate (custom date validation logic)
78- Disabling weekends or specific dates
79- Date validation patterns
80
81### Date Navigation
82📄 **Read:** [references/date-navigation.md](references/date-navigation.md)
83- DisplayDate property for programmatic navigation
84- Programmatic view switching
85- AllowViewNavigation property
86- NavigateToAdjacentMonth (leading/trailing date navigation)
87- Swipe gestures for month/year navigation
88- Header tap navigation between views
89
90### Calendar Modes and Display Options
91📄 **Read:** [references/calendar-modes.md](references/calendar-modes.md)
92- Default mode (inline display)
93- Dialog mode (centered popup)
94- RelativeDialog mode (positioned popup)
95- CalendarRelativePosition enum (AlignTop, AlignBottom, AlignToLeftOf, AlignToRightOf, etc.)
96- IsOpen property for programmatic control
97- PopupWidth and PopupHeight customization
98- Date picker patterns
99
100### Customization and Styling
101📄 **Read:** [references/customizations.md](references/customizations.md)
102- Month cell customization (dates, today, trailing/leading)
103- Text styles (TextStyle, TodayTextStyle, DisabledDatesTextStyle)
104- Background colors for all cell states
105- Weekend date styling
106- Special date highlighting with icons (Dot, Heart, Diamond, Star, Bell)
107- Year, Decade, and Century view customization
108- CalendarTextStyle properties (TextColor, FontSize, FontFamily)
109
110### Events and Interactions
111📄 **Read:** [references/events.md](references/events.md)
112- ViewChanged event (view/date range changes)
113- SelectionChanged event (date selection changes)
114- Tapped event (single tap on dates)
115- DoubleTapped event (double tap on dates)
116- LongPressed event (long press on dates)
117- Event arguments and data
118- Event handling patterns
119
120### Headers and Footers
121📄 **Read:** [references/headers-footers.md](references/headers-footers.md)
122- HeaderView customization (height, background, text style)
123- Header text format customization
124- ShowNavigationArrows property
125- HeaderTemplate for custom header UI
126- FooterView customization
127- Custom footer templates
128
129### Localization and Advanced Features
130📄 **Read:** [references/localization-advanced.md](references/localization-advanced.md)
131- Globalization and localization setup
132- CurrentUICulture configuration
133- Resource file creation for multiple languages
134- RTL (Right-to-Left) support
135- CalendarIdentifier (Gregorian, Hijri, etc.)
136- Calendar modes
137- Liquid glass effect
138- Advanced visual customization