如何使用C#读取大型Excel文件 [英] How to read big Excel Files using C#

查看:604
本文介绍了如何使用C#读取大型Excel文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Hello All,



我有一些大的excel文件(XLS和XLSX文件各约250兆字节),我想在.NET窗口应用程序中阅读。我尝试过使用ACE和JET数据库提供程序的OLEDB。一旦我调用Open()连接方法,它们都会给出驱动程序错误。 ACE驱动程序无法完成这项工作。



我不想使用Excel Inter-op作为最终用户的机器没有安装Office而我不能使用任何第三方付费组件。我试过像OpenXML阅读器和其他替代品这样的免费组件,但是它们都失败了。



请尽快给我一些解决方案。在此先感谢您的帮助。 :)

Hello All,

I have some big excel files (XLS and XLSX files approximately 250 megabytes each) which I want to read in my .NET windows applications. I have tried OLEDB uing both ACE and JET database providers. Both of them give "Driver Error" as soon as I call Open() method of connection. ACE driver fails to do the job.

I don't want to use Excel Inter-op as end user's machine don't have Office installed and I can't use any third party paid components. I tried free components like OpenXML reader and other alternates but they fail.

Kindly suggest me some solution ASAP. Thanks in advance for help. :)

推荐答案

250Mb也是MS Excel的问题,尝试创建更小的文件。



另请尝试以下组件: http://epplus.codeplex.com/ [ ^ ]
250Mb will be a problem with MS Excel also, try creating smaller files.

Also try this component : http://epplus.codeplex.com/[^]


这篇关于如何使用C#读取大型Excel文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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