0

Per client request, we need to export some of our database tables to an excel sheet. What is the most straight forward way to do this? What ever processing we do will be from the server and sent down to the browser as a file preferably.

Note: I was using LinqToExcel to read/parse excel files, I was hoping to find as good of a tool for writing to excel files.

ASP.NET 4, MVC3

2
  • See this answer Commented Sep 12, 2012 at 3:02
  • Which version of Excel? There are a lot of free options for creating .XLSX files. .XLS files, not so much. Commented Sep 12, 2012 at 3:29

3 Answers 3

3

I've used EPPlus with great results. Never had an issue with it and the API is sensible.

Sign up to request clarification or add additional context in comments.

Comments

0

Does it have to be excel format or can it be csv files?

I wrote an controller action that writes out a csv file and then load and process it in excel.

2 Comments

Can CSV files simply be loaded into Excel? Or is there any extra processing that must be done for excel to "play nice" with it?
CSV will work fine with Excel - just so long as you don't want to use any formatting e.g. make things bold, set column widths, row heights etc
0

I always use EPPlus from code project for creating excel files. This has more features

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.