isqueenie Report post Posted March 8, 2013 Hi I'm using c# to generate my chart data, would like to add linked charts as well and change chart type. Please advise how to configure link in c#, thanks In c# i'd call a function to generate the xml data then place the chart in Literal: string chartXml; chartXml = ScenarioChart.ChartFinancialTrend(SID.ToString()); litFinancial.Text = FusionCharts.RenderChart("../Charts/MSCombi2D.swf", "", chartXml.ToString(), "BudgetOverview", "100%", "280", false, false); The javascript for configure link but I need to do it in c# <script type="text/javascript" ><!-- var rootChart = new FusionCharts( "../../../../Charts/Column2D.swf", "myChartId", "680", "250", "0", "1" ); rootChart.setXMLUrl( "MuliLevelLinkedData.xml" ); rootChart.render( "parentChartContainer" ); rootChart.configureLink ( [ { overlayButton: { message: ' « Annual Sales' } }, { overlayButton: { message: ' « Quarterly Sales'} }, { swfUrl: '../../../../Charts/Pie3D.swf', width: '225', height: '200', renderAt: 'weeklyChartContainer', insertMode: 'append', overlayButton: { message: 'Close' } } ] ); Share this post Link to post Share on other sites
Sanjukta Report post Posted March 8, 2013 Hi, Hi I'm using c# to generate my chart data, would like to add linked charts as well and change chart type. Please advise how to configure link in c#, thanks In c# i'd call a function to generate the xml data then place the chart in Literal: string chartXml; chartXml = ScenarioChart.ChartFinancialTrend(SID.ToString()); litFinancial.Text = FusionCharts.RenderChart("../Charts/MSCombi2D.swf", "", chartXml.ToString(), "BudgetOverview", "100%", "280", false, false); The javascript for configure link but I need to do it in c# <script type="text/javascript" ><!-- var rootChart = new FusionCharts( "../../../../Charts/Column2D.swf", "myChartId", "680", "250", "0", "1" ); rootChart.setXMLUrl( "MuliLevelLinkedData.xml" ); rootChart.render( "parentChartContainer" ); rootChart.configureLink ( [ { overlayButton: { message: ' « Annual Sales' } }, { overlayButton: { message: ' « Quarterly Sales'} }, { swfUrl: '../../../../Charts/Pie3D.swf', width: '225', height: '200', renderAt: 'weeklyChartContainer', insertMode: 'append', overlayButton: { message: 'Close' } } ] ); Could you please try using the following code snippet in your "Default.aspx" page and see if this helps? Ex: <form id="form1" runat="server"> <div> <asp:Literal ID="Literal1" runat="server"></asp:Literal> <script type="text/javascript"> ChartID.configureLink( { swfUrl: 'FusionCharts/Pie3D.swf', width: '30%', overlayButton: { message: 'Back Button', bgColor: '999999', borderColor: 'cccccc', fontColor: 'FF0000', padding: '10' } }, 0); </script> </div> </form> Hope this helps. Share this post Link to post Share on other sites