More in this section

Forums / Developing with Sitefinity / RadScheduler renders seven times on Sitefinity v3.6 SP1 page

RadScheduler renders seven times on Sitefinity v3.6 SP1 page

4 posts, 0 answered
  1. Les
    Les avatar
    5 posts
    Registered:
    18 Sep 2006
    28 May 2009
    Link to this post
    I added a RadScheduler control to an ASCX user control and then added the user control to a Sitefinity page. The RadScheduler gets its events (appointments) from custom database tables. The events show up in the scheduler but the scheduler is rendered 7 times on the Sitefinity page. However, the same user control added to a standalone (outside Sitefinity) ASPX page renders just once--which is what is intended.

    Any ideas why it shows up seven times?
  2. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    28 May 2009
    Link to this post
    Hello Les,

    Thank you for suing our services.

    Could you send the control and code behind of it. We cannot tell you for sure what the problem is before we test the control locally.

    Greetings,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
  3. Les
    Les avatar
    5 posts
    Registered:
    18 Sep 2006
    28 May 2009
    Link to this post
    The ASCX file is as follows:

    1 <%@ Control Language="C#" AutoEventWireup="true" CodeFile="CalendarUC.ascx.cs" Inherits="UserControls_CalendarUC" %> 
    2 <%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %> 
    3 <telerik:radscheduler id="RadScheduler1" runat="server" hourspaneltimeformat="htt" validationgroup="ctl00_RadScheduler1" selectedview="MonthView"></telerik:radscheduler> 
    4  

    And the ASCX.CS file is:

    1 using System; 
    2 using System.Data; 
    3 using System.Configuration; 
    4 using System.Collections; 
    5 using System.Web; 
    6 using System.Web.Security; 
    7 using System.Web.UI; 
    8 using System.Web.UI.WebControls; 
    9 using System.Web.UI.WebControls.WebParts; 
    10 using System.Web.UI.HtmlControls; 
    11  
    12 using CBA.Business; 
    13 using CBA.Entities; 
    14  
    15 public partial class UserControls_CalendarUC : System.Web.UI.UserControl 
    16
    17     protected void Page_Load(object sender, EventArgs e) 
    18     { 
    19         if (!IsPostBack) 
    20         { 
    21             CalendarEventManager cem = new CalendarEventManager(); 
    22             TList<CalendarEvent> events = cem.GetEvents(); 
    23             RadScheduler1.DataKeyField = CalendarEventColumn.CalendarEventId.ToString(); 
    24             RadScheduler1.DataSubjectField = CalendarEventColumn.Title.ToString(); 
    25             RadScheduler1.DataStartField = CalendarEventColumn.StartDate.ToString(); 
    26             RadScheduler1.DataEndField = CalendarEventColumn.EndDate.ToString(); 
    27             RadScheduler1.DataSource = events; 
    28         } 
    29     } 
    30
    31  

  4. Ivan Dimitrov
    Ivan Dimitrov avatar
    16072 posts
    Registered:
    12 Sep 2017
    28 May 2009
    Link to this post
    Hi Les,

    We are not able to reproduce the problem you have using our datasource and the same code logic.

    All the best,
    Ivan Dimitrov
    the Telerik team

    Instantly find answers to your questions on the new Telerik Support Portal.
    Check out the tips for optimizing your support resource searches.
Register for webinar
4 posts, 0 answered