0
votes

I am working on project where I want to integrate NSCalendar functionality in my app. Hence I googled and I found this solution. It give me all months in the year and also I can select particular date. that's fine. But I wanted to disable all saturdays and sundays of every month somehow I tried to do it but when I tap previous month or next month it changes the selection. I have gone through almost all stackoverflow questions But I didn't find proper way to do it. I request you to all Is there any flexible solution on this where I can disable weekends and any particular date. The flow should be like this:

  1. Run the application current month is display and all sat & sun disabled.
  2. When tap on next month or previous month, the respective sat & sun should be disable as per that month.
  3. Functionality for any particular date that I want to disable.
1
Can you please add some code to it so that we are able to better understand the problem at handAkhilesh Sharma
I want complete new solution on that because whatever code I have written is not working perfectly.iMash
It will be better that you share the code because that will give us the hint what you are trying to achieveAkhilesh Sharma

1 Answers

1
votes

Hello i updated the files and i created an array of disabled days please check the code form here

RootViewController.m file http://shorttext.com/l7iKEdf

RootViewController.h file http://shorttext.com/lFaath

just replace these files with the original files from the link you provided you will find that i added a disabledDays NSMutableArray add any integers to it to it like following 0 = sat 6 = friday and that day will be disabled