Export to Excel,Word , Pdf, Html,CSV
The data could be a C# class or a JSON string or a CSV string or a DataTable
NuGet package at https://www.nuget.org/packages/ExporterWordExcelPDF/
The source code has tests and a console project for easy testing the package
Code examples in C# / JavaScript at https://github.com/ignatandrei/Exporter/wiki
Demo online at http://exporter.azurewebsites.net/
You can contribute to the project - read https://github.com/ignatandrei/Exporter/wiki/Help-the-project
PS: Just to make you an idea, this can be the code to export to Excel
List<Person> listWithPerson = ... //obtained from database
var export=new ExportExcel2007<Person>();
var data = export.ExportResult(listWithPerson);
File.WriteAllBytes("a.xlsx", data);
Process.Start("a.xlsx");
(Do not forget
using ExporterObjects;
using ExportImplementation;
)
You can also watch video tutorials at YouTube
But is better to read the Wiki