Articles in this section

How to render Scheduler within UpdatePanel ?

This knowledge base article explains the way to prevent the browser reloading while using Scheduler server-side events.

 

Step 1: Create an Scheduler sample by referring the following online sample link.

https://help.syncfusion.com/aspnet/schedule/getting-started

 

Step 2: Render the Scheduler with in UpdatePanel and include the OnServerAppointmentClick Scheduler server-side event as shown in the following code example.

<asp:Content ID="BodyContent" ContentPlaceHolderID="MainContent" runat="server">
    <asp:UpdatePanel ID="UpdatePanel1" runat="server">
        <Triggers>
            <asp:AsyncPostBackTrigger ControlID="Schedule1" />
        </Triggers>
        <ContentTemplate>
            <ej:Schedule ID="Schedule1" ClientIDMode="Static" Height="525px" Width="100%" CurrentDate="5/5/2014" runat="server" DataSourceID="SqlDataSource1" OnServerAppointmentClick="Schedule1_ServerAppointmentClick" >
                <AppointmentSettings Id="Id" Subject="Subject" AllDay="AllDay" StartTime="StartTime" EndTime="EndTime" Recurrence="Recurrence" RecurrenceRule="RecurrenceRule" />
            </ej:Schedule>
        </ContentTemplate>
    </asp:UpdatePanel>
    <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:DefaultConnection %>" SelectCommand="SELECT * FROM [Appointment]"></asp:SqlDataSource>
</asp:Content>

 

Step 3: Define the alert tag with in server-side event function as shown in the following code example.

protected void Schedule1_ServerAppointmentClick(object sender, Syncfusion.JavaScript.Web.ScheduleEventArgs e)
{
    ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Appointment is clicked');", true);
}

 

Step 4: Run the sample and whenever the appointment is clicked, alert message will be shown without reloading the browser window.

Sample: https://www.syncfusion.com/downloads/support/directtrac/general/ze/Sample-1756258022

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Access denied
Access denied