2

I am using the Kal calendar component for a leave management application on Xcode 4.2. I am developing the application for iPad.

I am highlighting From Date and To Date when the user applies for a leave in a particular month using tap on a tile method and setting the background color for that tile.

It is working fine, the only issue being, when I navigate from one month to another and come back to the previous month, the highlighted leaves for that month are not shown on the calendar.

In short, while navigating between months the highlighted color for the respective tiles is lost. I want that color for tiles to remain intact even if I navigate to a different month and come back to original.

How do I fix this problem?

iDev
  • 23,310
  • 7
  • 60
  • 85
  • If i remember this right tiles are redrawn each time you change month. And you have to 'tell' the KAL in TileForDate (or something like that) what kind od tile you want. KAL itself doesn't 'remember' what you did before to certain tiles and it doesn't care :) – Rok Jarc Feb 22 '12 at 14:26
  • what can i do to disable tiles for dates before the current date . – Amit Nalawade Feb 24 '12 at 10:40
  • not sure what you mean by disable? but in that tileForDate function you could check the date and if if's before the current date you return 'disabled' tile. if you want them to be 'unclickable' you could set their userInteractionEnabled to NO. – Rok Jarc Feb 24 '12 at 10:45
  • thnks..sure il try that...also is there anyway i can highlight some tiles and keep the higlighted part throughout my application.Currently highlighted stuff goes away while navigating between months. – Amit Nalawade Feb 24 '12 at 18:38
  • You'll have to highlite tiles each time you create them (again, with tileForDate) – Rok Jarc Feb 24 '12 at 18:59
  • i saw one of the SAP applications and they have managed to keep highlighted tiles as it is for a particular month when you navigate between diff months.so i was trying to find out if that can be done using kal calendar – Amit Nalawade Mar 03 '12 at 07:00
  • any idea how this can de done ? – Amit Nalawade Mar 06 '12 at 11:25
  • last time i used KAL was about two years ago - so i'll have to take a look and it might take a while. i'm not at mac at the moment, but i will check it out. – Rok Jarc Mar 06 '12 at 11:57
  • please do..because i need to implement that feature in my application asap.Appreciate your help . – Amit Nalawade Mar 16 '12 at 12:27

0 Answers0