Answer the question
In order to leave comments, you need to log in
What to use to quickly generate an Excel file?
ASP.NET MVC project. The task is to generate a simple Excel file of 4-5 pages from the user's data with some simple design, possibly with a couple of graphs. Moreover, it is desirable not only to generate it and save it on hard, but immediately give it back to the user, without saving it to hard. Actually, what approach is the simplest in terms of writing code and more reliable.
Answer the question
In order to leave comments, you need to log in
Except for this requirement:
then definitely EPPlus (in nuget: EPPlus ), you are unlikely to find something better that does not require an installed Office. As for "immediately give to the user" - you need to see if the workbook can write to Stream, and not to a file.
UPD: judging by the designer ExcelPackage(Stream newStream)
, he can. So write to MemoryStream and give it to the user. Don't forget to set the Content-Type as needed)
XLS or XLSX?
There are libraries for both, for example NPOI, for the second one it is quite easy to write "bicycle".
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question