Exporting Reports

21 Jul 20161 minute to read

Essential ReportWriter provides support for Exporting a report as a PDF, Word, Excel, PPT and HTML documents with the help of the class ReportWriter. The report elements such as Tablix, matrices, charts, gauges, shapes, and text boxes are supported in this feature.

Exporting Report as PDF

The report used in ReportWriter can be exported as PDF document using the following code.

ReportWriter reportWriter = new ReportWriter(reportpath, dataSources);
reportWriter.Save("Sample.pdf", WriterFormat.PDF);

Exporting Report as Word

The report used in ReportWriter can be exported as Word document using the following code.

ReportWriter reportWriter = new ReportWriter(reportpath, dataSources);
reportWriter.Save("Sample.doc", WriterFormat.Word);

Exporting Report as Excel

The report used in ReportWriter can be exported as Excel document using the following code.

ReportWriter reportWriter = new ReportWriter(reportpath, dataSources);
reportWriter.Save("Sample.xls", WriterFormat.Excel);

Exporting Report as HTML

The report used in ReportWriter can be exported as HTML document using the following code.

ReportWriter reportWriter = new ReportWriter(reportpath, dataSources);
reportWriter.Save("Sample.html", WriterFormat.HTML);

Exporting Report as PPT

The report used in ReportWriter can be exported as PPT document using the following code.

ReportWriter reportWriter = new ReportWriter(reportpath, dataSources);
reportWriter.Save("Sample.ppt", WriterFormat.PPT);