or



Hi all,
My problem is this: when I move a working radChart to a master/content page scenario the chart shows me the message 'there is no or empty series'. The same code works ok when I place it in a regular aspx page. I tried adding the RadScriptManager to the masterpage but that didn't work. I went through this forum and found a lot of posts on the masterpage problem but no solution to my problem, unfortunately. Here is the code
aspx page
<%@ Page Language="C#" AutoEventWireup="true" MasterPageFile="~/masterpages/ControlHolder.master" CodeBehind="test2.aspx.cs" Inherits="TestLme2" %> <%@ MasterType virtualpath="~/masterpages/ControlHolder.Master" %> <%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %> <%@ Register assembly="Telerik.Web.UI" namespace="Telerik.Charting" tagprefix="telerik" %> <asp:Content ID="ContentMain" ContentPlaceHolderID="cntControl" Runat="Server"> <telerik:RadChart ID="radChart1" runat="server" Width="700px" AutoLayout="True" Skin="Default2006"> <Series> <telerik:ChartSeries Name="Series 1"> <Appearance> <FillStyle MainColor="150, 150, 150" SecondColor="194, 194, 194"> </FillStyle> <Border Color="Silver" /> </Appearance> </telerik:ChartSeries> <telerik:ChartSeries Name="Series 2"> <Appearance> <FillStyle MainColor="215, 215, 214" SecondColor="241, 241, 241"> </FillStyle> <Border Color="Silver" /> </Appearance> </telerik:ChartSeries> </Series> <PlotArea> <XAxis> <Appearance Color="Silver" MajorTick-Color="Silver"> <MajorGridLines Color="Silver" /> </Appearance> </XAxis> <YAxis> <Appearance Color="Silver" MajorTick-Color="Silver" MinorTick-Color="Silver"> <MajorGridLines Color="Silver" /> <MinorGridLines Color="224, 224, 224" /> </Appearance> </YAxis> <Appearance Dimensions-Margins="18%, 22%, 12%, 10%"> <FillStyle MainColor="White" SecondColor="White" FillType="Solid"> </FillStyle> <Border Color="Silver" /> </Appearance> </PlotArea> <Appearance> <FillStyle MainColor="WhiteSmoke"> </FillStyle> <Border Color="Silver" /> </Appearance> <ChartTitle> <Appearance Position-AlignedPosition="Top"> </Appearance> <TextBlock> <Appearance TextProperties-Color="Gray"> </Appearance> </TextBlock> </ChartTitle> <Legend> <Appearance Dimensions-Margins="18%, 1%, 1px, 1px"> <Border Color="Silver" /> </Appearance> </Legend> </telerik:RadChart> <br /> <br /> </asp:Content>and the aspx.cs page:
protected void Page_Load(object sender, EventArgs e) { if (!Page.IsPostBack) { DataTable tbl = new DataTable(); DataColumn col = new DataColumn("Value"); col.DataType = typeof(int); tbl.Columns.Add(col); col = new DataColumn("Date"); col.DataType = typeof(double); tbl.Columns.Add(col); tbl.Rows.Add(new object[] { 5, DateTime.Today.ToOADate() }); tbl.Rows.Add(new object[] { 4, DateTime.Today.AddDays(1).ToOADate() }); tbl.Rows.Add(new object[] { 3, DateTime.Today.AddDays(2).ToOADate() }); tbl.Rows.Add(new object[] { 6, DateTime.Today.AddDays(3).ToOADate() }); tbl.Rows.Add(new object[] { 3, DateTime.Today.AddDays(4).ToOADate() }); tbl.Rows.Add(new object[] { 6, DateTime.Today.AddDays(5).ToOADate() }); ChartSeries ser = new ChartSeries("Value"); ser.DataYColumn = "Value"; ser.DataXColumn = "Date"; radChart1.Series.Add(ser); radChart1.PlotArea.XAxis.IsZeroBased = false; radChart1.PlotArea.XAxis.Appearance.ValueFormat = ChartValueFormat.ShortDate; radChart1.DataSource = tbl; radChart1.DataBind(); } }Anyone have any ideas why this is happening?
Thanks,
Peter
<telerik:RadGrid ID="UserTicketGrid" runat="server" AllowSorting="True"<br> AllowPaging="True" PageSize="5" CellSpacing="0" <br> Width="600px" OnUpdateCommand="UserTicketGrid_UpdateCommand" AllowAutomaticUpdates="false"><br> <br> <ClientSettings><br> <br> <Selecting AllowRowSelect="true"/><br> <ClientEvents OnRowClick="rowClick" OnCommand="oncommand" /><br> </ClientSettings><br> <MasterTableView EditMode="InPlace" AutoGenerateColumns="false"><br> <br> <Columns><br> <telerik:GridEditCommandColumn UniqueName="EDIT" HeaderText="<%$Resources:Resource,edit %>" ButtonType="ImageButton" EditImageUrl="App_Themes/WebPortalTheme/images/edit_icon.png"/><br> <telerik:GridBoundColumn DataField="SUPP_SERV_ID" Display="false" ReadOnly="true" HeaderText="ID" UniqueName="SUPP_SERV_ID"></telerik:GridBoundColumn><br> <telerik:GridBoundColumn DataField="SUPP_SERV_TITLE" HeaderText="<%$Resources:Resource,gridtitle %>" UniqueName="TITLE" ReadOnly="true"></telerik:GridBoundColumn><br> <telerik:GridDropDownColumn DataField="TICKET_STATUS_ID" DataSourceID="ds_TICKETStatus" HeaderText="<%$Resources:Resource,status %>"<br> UniqueName="STATUS_ID" ListTextField="TICKET_STATUS_NAME" ListValueField="TICKET_STATUS_ID"></telerik:GridDropDownColumn><br> <telerik:GridBoundColumn DataField="SUPP_SERV_RATE" HeaderText="<%$Resources:Resource,rate %>" UniqueName="RATE" ReadOnly="true"> </telerik:GridBoundColumn><br> <telerik:GridBoundColumn DataField="SUPP_SERV_DATE_POSTED" HeaderText="<%$Resources:Resource,dateposted %>" UniqueName="POSTEDDATE" ReadOnly="true"></telerik:GridBoundColumn><br> <telerik:GridBoundColumn DataField="ISPUBLIC" HeaderText="<%$Resources:Resource,ispublic %>" UniqueName="ISPUBLIC" ReadOnly="true"></telerik:GridBoundColumn><br> </Columns><br> <br> </MasterTableView><br> </telerik:RadGrid><br>UserDataT = WebsiteDataHelper.GetUserTickets(UserID, type, realID, versionID);<br> if (UserDataT.Rows.Count != 0)<br> {<br> GridIsEmpty.Style["display"] = "none";<br> <br> UserTicketGrid.DataSource = UserDataT;<br> UserTicketGrid.DataBind();<br> }<br><br>protected void UserTicketGrid_UpdateCommand(object sender, GridCommandEventArgs e)<br> {<br><br>/// i need to access GridDropDownColumn selected value here how can i acheive this<br><br> }