Webchart in aspContent usin Masterpage don't Fire ClickEvent
Posted: Tue Aug 01, 2006 11:48 am
Hello,
I think there is a bug with webchart when you place it in a page ex:Default2.aspx between 2 tags <asp:Content> and use a masterpage.
ClickBackground events and ClickSeries events are not Fired.
Is there a bug ?
This is critical for me.
Thanks
Ps : See my code below
////////////// Default2.aspx ////////////
<%@ Register Assembly="TeeChart" Namespace="Steema.TeeChart.Web" TagPrefix="tchart" %>
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" MasterPageFile="MasterPage.master"%>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentColumn" Runat="server" >
<form id="form1" runat="server">
<div>
<tchart:WebChart ID="WebChart100" style="Z-INDEX: 102; " runat="server" AutoPostback="True" TempChart="Session" Config="AAEAAAD/////AQAAAAUZWVDaGFydAs=" Height="290px" Width="432px" OnClickBackground="WebChart100_ClickBackground" GetChartFile="GetChart.aspx" OnAfterDraw="WebChart100_AfterDraw" />
</div>
</form>
</asp:Content>
////////////// Default2.aspx.cs ////////////
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class Default2 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void WebChart100_ClickBackground(object sender, ImageClickEventArgs e)
{
///////is not fired!
}
}
////////////////// MasterPage.master /////
<%@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPage" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<div>
<asp:contentplaceholder id="ContentColumn" runat="server"></asp:contentplaceholder>
</div>
</body>
</html>
////////////////// MasterPage.master.cs /////
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class MasterPage : System.Web.UI.MasterPage
{
protected void Page_Load(object sender, EventArgs e)
{
}
}
I think there is a bug with webchart when you place it in a page ex:Default2.aspx between 2 tags <asp:Content> and use a masterpage.
ClickBackground events and ClickSeries events are not Fired.
Is there a bug ?
This is critical for me.
Thanks
Ps : See my code below
////////////// Default2.aspx ////////////
<%@ Register Assembly="TeeChart" Namespace="Steema.TeeChart.Web" TagPrefix="tchart" %>
<%@ Page Language="C#" AutoEventWireup="true" CodeFile="Default2.aspx.cs" Inherits="Default2" MasterPageFile="MasterPage.master"%>
<asp:Content ID="Content1" ContentPlaceHolderID="ContentColumn" Runat="server" >
<form id="form1" runat="server">
<div>
<tchart:WebChart ID="WebChart100" style="Z-INDEX: 102; " runat="server" AutoPostback="True" TempChart="Session" Config="AAEAAAD/////AQAAAAUZWVDaGFydAs=" Height="290px" Width="432px" OnClickBackground="WebChart100_ClickBackground" GetChartFile="GetChart.aspx" OnAfterDraw="WebChart100_AfterDraw" />
</div>
</form>
</asp:Content>
////////////// Default2.aspx.cs ////////////
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class Default2 : System.Web.UI.Page
{
protected void Page_Load(object sender, EventArgs e)
{
}
protected void WebChart100_ClickBackground(object sender, ImageClickEventArgs e)
{
///////is not fired!
}
}
////////////////// MasterPage.master /////
<%@ Master Language="C#" AutoEventWireup="true" CodeFile="MasterPage.master.cs" Inherits="MasterPage" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" >
<head runat="server">
<title>Untitled Page</title>
</head>
<body>
<div>
<asp:contentplaceholder id="ContentColumn" runat="server"></asp:contentplaceholder>
</div>
</body>
</html>
////////////////// MasterPage.master.cs /////
using System;
using System.Data;
using System.Configuration;
using System.Collections;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
public partial class MasterPage : System.Web.UI.MasterPage
{
protected void Page_Load(object sender, EventArgs e)
{
}
}