Jump to content
Software FX Community

eromurugan

Members
  • Posts

    5
  • Joined

  • Last visited

Posts posted by eromurugan

  1. Hi,

    I need to display the chart on click of a button in a web page. 

    On click of a button, I hit the DB to get data and bind them to the chart controls in the web page.

    On second click of the button, the data is bound to the chart control for second time. this makes bar chart with two colors for each of the data bound to it.

    I need to clear the datasource set to chart and reassign new datasource. How can this me achieved? Help me with some suggestions.

  2. Hi, I have web page with multiple Chart FX 7.0 Controls in it. I want to export all the content in a container like Panel to excel. Panel contains the charts. I am using the following code to achieve it.

    string exportContent = string.Empty;

    HttpResponse response = CreateExcelFile(fileName);using (StringWriter sw = new StringWriter()) {

    using (HtmlTextWriter htw = new HtmlTextWriter(sw)) {HtmlTable t = new HtmlTable();

    HtmlTableRow top = new HtmlTableRow();HtmlTableCell tcell = new HtmlTableCell();

    tcell.Controls.Add(control);

    top.Cells.Add(tcell);

    t.Rows.Add(top);

    t.RenderControl(htw);

    HttpContext.Current.Response.Write(sw.ToString());HttpContext.Current.Response.End();

    } }

    I am getting error Object Reference not set at line t.RenderControl(htw);

    Please help me. 

    Thanks in advance.

     

×
×
  • Create New...