Click here to Skip to main content
15,912,329 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I Just want to Convert the Database table with large data into the Excel sheet in my C#.Net Windows application but not using the Microsoft.excel;(must be freeware & platform independent) so is any another way by using some open excel or anything???
Any type of help would be appreciate as I need it very much..I will wait, just share your knowledge to check yourself!!!
Thanks in advance,
Posted
Comments
Zoltán Zörgő 8-Oct-12 2:48am    
1) It will never be "platform independent".
2) You want XLS or XLSX?
3) Do you really need native excel format, or others readable by excel can also be used?
Killer Coder 8-Oct-12 2:59am    
Anyone will be ok XLS, XLSX because both will work.Need native excel format.
& why it will never be platform independent?
Zoltán Zörgő 8-Oct-12 3:06am    
Because .net is not platform independent. Actually it depend on what you mean under "platform independence". See my answer down there.

You can use openxml SDK

Check this article.
Export GridView Data to Excel using OpenXml[^]
 
Share this answer
 
There are libraries out there that can help you. Not all have the same functionality covered, and not all have the same licensing.
- This one could be used for the old (xls) format: http://code.google.com/p/excellibrary/[^]
- Here you can read an article about how to write an xlsx on your own: How to Read and Write .xlsx (Excel 2007) file - Part I[^]
- You can trick Excel easily by creating a proper html file and saving it with xls extension. Will work like a charm :).
- Excel has ODS support: How to Read and Write ODF/ODS Files (OpenDocument Spreadsheets)[^]
- And there are other component out there you might find interesting, like this one: http://npoi.codeplex.com/[^]
 
Share this answer
 
v2
 
Share this answer
 
Comments
Killer Coder 8-Oct-12 5:27am    
I don't think it will be acceptable by my client because though its free component to use but Support is payable.
but anyway thanks Miracle to give me an alternate way.
[no name] 8-Oct-12 5:50am    
You can add your problem on the comment section after these article, I believe someone will help you.give it a try.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900