如何在C#中使用excelsheet在excelsheet中从多行和多列中选择项目 [英] How to select items from multiple rows and columns using excelsheet in asp with c#

查看:111
本文介绍了如何在C#中使用excelsheet在excelsheet中从多行和多列中选择项目的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

尊敬的先生/女士


我对我的项目非常紧张,我正在用c#asp.net做我的项目
而且我必须使用excel工作表,但我不知道如何编写其查询
我必须从多个行和列中获取数据.所以任何人都可以帮助我.

Dear sir/madam


I am very tense about my project i am doing my project in c# asp.net
and i have to use excel sheet but i dont know how to write its query
i have to fetch data from multiple rows and columns. So could anyone plese help me .

推荐答案

我不建议使用Interop来访问Excel中的数据.这很容易出错,如果出现问题(例如对话框弹出窗口),可能会锁定服务器.

如果您想要功能齐全且有钱的东西,我建议您使用第三方软件.我曾与 Aspose [ ^ ]和它很坚固.

如果以上都不可行,您将只剩下OleDb即可连接到电子表格并提取数据.此处是指向示例 [
I would not recommend using Interop to access the data in Excel. It''s very error prone and could potentially lock up the server if something goes awry (ex. dialog popups).

If you want something fully featured and have the money, I would recommend using third party software. I have worked with Aspose[^] and it is solid.

If the above is out of the question, you''ll only be left with OleDb to connect to the spreadsheet and pull data. Here''s a good link to an example[^].


这篇关于如何在C#中使用excelsheet在excelsheet中从多行和多列中选择项目的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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