导出到Exel而不使用Microsoft.Excel lib? [英] Export to Exel without Using Microsoft.Excel lib?

查看:75
本文介绍了导出到Exel而不使用Microsoft.Excel lib?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我只想将包含大数据的数据库表转换为C#.Net Windows应用程序中的Excel工作表,但不使用Microsoft.excel;(必须是免费软件和平台无关的),因此还有另一种方法通过使用一些开放的excel或其他工具?
我非常需要任何帮助,我们将不胜感激.我会等待,只需分享您的知识以检查自己!!
预先感谢,

解决方案

您可以使用openxml SDK

查看本文.
使用OpenXml将GridView数据导出到Excel [ ^ ]

有一些可以帮助您的库.并非所有人都具有相同的功能,也并非所有人都具有相同的许可.
-此格式可用于旧的(xls)格式: http://code.google.com/p/excellibrary/ [^ ]
-在这里您可以阅读有关如何自行编写xlsx的文章:如何阅读和写入ODF/ODS文件(OpenDocument电子表格) [ http://npoi.codeplex.com/ [ ^ ]


您可以使用此免费数据导出组件 [ 9将数据导出到Excel for ASP的解决方案. NET [ ^ ]
无需从数据库自动将数据导出到Excel,Word和PDF [ ^ ]
如何将自定义格式数据导出到Excel [ ^ ]


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,

解决方案

You can use openxml SDK

Check this article.
Export GridView Data to Excel using OpenXml[^]


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/[^]


You can use this free dataexport component [^] to export database table to excel, please see below article in detail:
9 Solutions to Export Data to Excel for ASP.NET[^]
Export Data to Excel, Word, PDF without Automation from DataBase[^]
How to export customized format data to Excel[^]


这篇关于导出到Exel而不使用Microsoft.Excel lib?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆