0

I use FSCalendar and i'm trying to close past dates, but i or close the whole calendar for selecting dates or open all dates to select.

How i can close only past dates from today's date?

This should be done in this method:

func calendar(_ calendar: FSCalendar, shouldSelect date: Date, at monthPosition: FSCalendarMonthPosition) -> Bool {


}

I have found a lot of answers on this subject, but nowhere answer how to write code.

rmaddy
  • 314,917
  • 42
  • 532
  • 579

1 Answers1

1

The simple way is you can set minimum date method on **FSCalendarDataSource*

func minimumDate(for calendar: FSCalendar) -> Date 
{ 
   return Date() 
}
iMSaM
  • 118
  • 5