Hi Jaja,
1. Product information.
2. 2. Web.config
If you are using Chart[Web] in sharepoint 2010. Please
download the sample from below link.
The chart broken image issue occurs if the chart handlers
are not specified in the web.config file. In order to run the Chart application
in web server, you need to add the chart handlers which specifies the name,
path and type of the handlers in the webconfig file under the following tag.
System.webserver => handlers. Please find the following
code snippet to achieve this.
[web.config]
<system.webServer>
<handlers>
<add name="SFChart" path="syncfusion_generate.ashx"
verb="*"
type="Syncfusion.Web.UI.WebControls.Chart.ChartWebHandler,Syncfusion.Chart.Web,
Version= x.x.x.x, Culture=neutral, PublicKeyToken=3d67ed1f87d44c89" />
</handlers>
</system.webServer>
If you are running the chart application in the local machine via Visual
studio, then it’s enough to add the handlers in “httpHandler” tag. But for
hosting it, you have to add the same in webserver handler tag too.
Please let us know your concerns.
Siva
# region XlsIO case "xlsio": exportFileName = fileName + ".xls"; file = fileName + ".emf"; if (!System.IO.File.Exists(Server.MapPath(file))) this.ChartWebControl1.SaveImage(Server.MapPath(file)); ExcelEngine engine = new ExcelEngine(); IApplication application = engine.Excel; //A new workbook with a worksheet is created. IWorkbook chartBook = application.Workbooks.Create(2); IWorksheet sheet = chartBook.Worksheets[0]; sheet.Pictures.AddPicture(Server.MapPath(file)); chartBook.SaveAs(exportFileName, ExcelSaveType.SaveAsXLS, Response, ExcelDownloadType.PromptDialog); chartBook.Close(); engine.Dispose(); OpenFile("XLsIO", exportFileName); break; # endregion
and i open the export xls , the chart is not bind data. how can i do this ?
Thanks you replay , again .
Hi Jaja,
We regret for inconvenience caused.
We are unable to reproduce the issue. We have prepared a simple chart sample for exporting chart to excel. The sample can be downloaded from the following link.
Could you please try the above sample and get back to us whether you are able to reproduce the issue? If not, could you please give more information or by reproducing the issue in the above sample so that we could sort out the issue and provide you with solution. The information provided would be of great help in resolving the issue.
Please let us know if any concerns.
Regards,
Siva