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

Rebind / Refresh problem

2 Answers 167 Views
Scheduler
This is a migrated thread and some comments may be shown as answers.
Karl
Top achievements
Rank 1
Karl asked on 07 May 2010, 04:23 PM
Hi,
I am having trouble refreshing my scheduler after an insert / update. The insert and updates both work fine but the scheduler does not refresh after each of these events, I have to press F5 or refresh the page to see the changes. I am using Subsonic as my datasource
protected void RadScheduler1_OnLoad(object sender, EventArgs e)  
    {  
        if (!IsPostBack)  
        {  
            SubSonic.Query q = new SubSonic.Query(TblSystemAvailability.Schema);  
            q.QueryType = SubSonic.QueryType.Select;  
            q.OrderBy = SubSonic.OrderBy.Desc(TblSystemAvailability.Columns.TimeStamp);  
 
            RadScheduler1.DataSource = TblSystemAvailability.FetchByQuery(q);  
        }  
    } 

And also using the following Ajax
<telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"    
    DefaultLoadingPanelID="RadAjaxLoadingPanel1">    
    <AjaxSettings>        
        <telerik:AjaxSetting AjaxControlID="RadScheduler1">    
            <UpdatedControls>        
                <telerik:AjaxUpdatedControl ControlID="RadScheduler1"    
                    LoadingPanelID="RadAjaxLoadingPanel1" />        
            </UpdatedControls>    
        </telerik:AjaxSetting>    
        <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">     
            <UpdatedControls>     
                <telerik:AjaxUpdatedControl ControlID="RadScheduler1" />     
            </UpdatedControls>     
        </telerik:AjaxSetting>     
    </AjaxSettings>        
</telerik:RadAjaxManager>  

 

After AppointmentInsert and AppointmentUpdate I am setting RadScheduler1.Rebind(), I have tried using Javascript to refresh but to no avail. If anybody has any ideas it would be much appreciated. Thanks.

 

 

2 Answers, 1 is accepted

Sort by
0
Accepted
T. Tsonev
Telerik team
answered on 10 May 2010, 02:22 PM
Hello Karl,

Thank you for the detailed explanation of the problem. I see that you're using the DataSource property to bind the control. This must be set on every postback, not only on the initial load. See this example - http://demos.telerik.com/aspnet-ajax/scheduler/examples/bindtolist/defaultcs.aspx

I hope this helps.

Regards,
Tsvetomir Tsonev
the Telerik team

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 Public Issue Tracking system and vote to affect the priority of the items.
0
Karl
Top achievements
Rank 1
answered on 10 May 2010, 04:01 PM
Yes indeed, that works a treat, thanks a lot.
Tags
Scheduler
Asked by
Karl
Top achievements
Rank 1
Answers by
T. Tsonev
Telerik team
Karl
Top achievements
Rank 1
Share this question
or