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

Can you refresh custom datasource on Postback?

1 Answer 194 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
antonio
Top achievements
Rank 1
antonio asked on 04 Jun 2008, 10:41 PM
Hello,
I have implemented a control with RadScheduler and a custom data source, and so far it works.

I have the following problem:
1) I have implemented a ContextMenu, that calls my own page that in turn modifies the table (appointmet) that feeds the custom data source. 
2) This page is loaded as a modal form, and when I close it I force a postback.
3) The problem is that the postback, reloads "MyDbSchedulerProvider" but it does not refresh the data.  So, if I change the dates using my form, it does not reflect in the scheduler until a switch views or click on advance month (if in the monthly view)

I wonder, is there any way to manually call the GetAppointments method in MyDbSchedulerProvider?

Thanks,

Antonio.

1 Answer, 1 is accepted

Sort by
0
T. Tsonev
Telerik team
answered on 05 Jun 2008, 05:13 PM
Hello Antonio,

The RadScheduler instance in the main page is not notified of the changes to the data source, so it loads it's data from the ViewState when the postback occurs. You should call the Rebind() method to force a data binding.

All the best,
Tsvetomir Tsonev
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
Tags
Scheduler
Asked by
antonio
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Share this question
or