This is a migrated thread and some comments may be shown as answers.

Refresh RadCalendar

2 Answers 223 Views
Calendar - Xamarin.iOS
This is a migrated thread and some comments may be shown as answers.
Ian
Top achievements
Rank 1
Ian asked on 19 Oct 2017, 04:53 PM

I have a subclass of RadCalender which has an additional collection of items, which I'm binding to the calendar using a custom cell.

So, I have two issues...

1. How do I asynchronously bind this additional collection to the calendar? (The data comes from a web service.)

2. How do I reload the data when it's changed?

2 Answers, 1 is accepted

Sort by
0
Ves
Telerik team
answered on 24 Oct 2017, 10:23 AM
Hi Ian,

You can find the task of asynchronous loading of items collections discussed in various threads out in the internet, e.g. this Stack Overflow thread. Onto the second question -- RadCalendar does not expose a method for full reload as it handles updates internally. In order to act on changes in your collection, you may consider using custom renderers, inheriting from the existing CalendarRenderer classes. You can then send messages to these renderers from your Xamarin Forms control using the Xamarin Forms MessagingCenter. Then, upon receiving these, you can invoke the corresponding native control's method: InvalidateUI on Windows, RebuildCalendar on Android and ReloadData on iOS.

Best regards,
Ves
Progress Telerik
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Feedback Portal and vote to affect the priority of the items
0
Ian
Top achievements
Rank 1
answered on 24 Oct 2017, 10:58 AM
Reassigning the AppointmentsSource triggers a rebind.
Tags
Calendar - Xamarin.iOS
Asked by
Ian
Top achievements
Rank 1
Answers by
Ves
Telerik team
Ian
Top achievements
Rank 1
Share this question
or