Afternoon SF team,
With the sfcalendar, is there a way to stop users from swiping / clicking & dragging on the view to go to the next or previous month view? I thought there might be an option on NavigationDirection of "None" but unfortunately its only Horizontal and Vertical
King regards,
Josh
Hi Josh,
Regarding Query: is there a way to stop users from swiping / clicking & dragging on the view to go to the next or previous month view?
As per the current implementation, there is no direct support to stop the swiping to prev and next views. But by using the MinimumDate and MaximumDate property of the calendar, you can restrict the navigation beyond the mentioned dates. Please find the UG documentation for the same.
UG links:
https://help.syncfusion.com/maui/calendar/date-restrictions#minimum-date
https://help.syncfusion.com/maui/calendar/date-restrictions#maximum-date
We have a KB documentation for the same. Please find the documentation from the following link.
KB link:
Also, by using AllowViewNavigation property of the calendar you can enable/ disable year, decade and century through cell interaction. Please find the UG documentation from the following link.
https://help.syncfusion.com/maui/calendar/date-navigation#allow-view-navigation
You can restrict the date selection/ clicking by using the below properties.
EnablePastDates – By setting the value as false, you can disable the dates before the today and restrict the selection for those dates.
https://help.syncfusion.com/maui/calendar/date-restrictions#enable-past-dates
SelectableDayPredicate – By using this, you can disable the particular selected date in a calendar. Please find the documentation from the following link.
https://help.syncfusion.com/maui/calendar/date-restrictions#selectable-day-predicate
We hope that this helps you. Please let us know if you need further assistance. We are happy to assist you.
Regards,
Indumathi R
Hi Indumathi,
I've used the max / min dates and it
Hi Josh,
Thank you for the update. We are glad to know that the issue will be resolved at your end. Please get in touch with us if you require any further assistance.
Regards,
Indumathi R