问题标签 [npoi]
For questions regarding programming in ECMAScript (JavaScript/JS) and its various dialects/implementations (excluding ActionScript). Note JavaScript is NOT the same as Java! Please include all relevant tags on your question; e.g., [node.js], [jquery], [json], [reactjs], [angular], [ember.js], [vue.js], [typescript], [svelte], etc.
c# - 如何使用 NPOI 库在 C# 中对 excel 中的数据进行排序
如何使用 C# 和 NPOI 库对 Excel 电子表格中的数据进行排序?
excel电子表格非常简单。有两列带有标题,“姓名”(A 列)和“生日”(B 列)。数据绝不是排序的。
我的目标是按名称的字母顺序对列表进行排序。当然,每个名称仍应与正确的生日相匹配。
我该怎么做呢?
c# - can not found npoi.xssf.usermodel
I wanna use npoi to manipulate .xlsx
files in VS2012/2010
. To do so I should import NPOI.XSSF.UserModel
, but when I add the npoi.dll
and try to import that, there is no XSSF
type of NPOI
at Using part. I mean that there is no "Using NPOI.XSSF
"
Any help?
c# - 如何为使用 NPOI 创建的 Excel 中的单元格设置验证
我NPOI
使用以下代码创建了一个 Excel 文件
我只是想在每个单元格中添加一些验证。例如:restrict cell 2 with inputs only 1,2,3
中Excel we can Set Data Validation
能。whole number
_specify Min and Max Value
任何实现这一目标的想法都会有很大帮助。
c# - NPOI 把 xlsx 文件弄得一团糟
我有以下代码可以写入现有的 XLSX 文件
使用 XLS 文件效果很好。
请帮忙。
问候, 里纳尔多
c# - 如何使用 NPOI 读取包含空单元格的 Excel 电子表格?
当我使用 NPOI 阅读 Excel 工作表时,会跳过空单元格。例如,该行包含它A, B, , C
,我使用它读取它
然后row.Cells[1].ToString()
将输出B
(如预期的那样),但row.Cells[2].ToString()
将输出C
而不是空字符串。有没有办法保留空单元格?谢谢。
c# - 如何使用 NPOI 读取数字单元格的未格式化内容?
我想读取数字单元格的未格式化内容(例如0.05
,代替5%
和123456
代替123,456.000
)。
我认为最简单的方法是更改单元格的格式:
但我不知道如何设置字符串/数字格式。
我用谷歌搜索的所有示例都来自POI
或HSSF
宇宙,它们不会为我做(我正在阅读Excel 2007
电子表格NPOI
)
c# - NPOI 与 ASP.NET (C#)
我试图让 NPOI 与 ASP.NET (C#) 一起工作,我想读取一个 excel 文件并将其放入数据集中。这是我尝试的代码:
我得到的错误是
奇怪的是,这实际上适用于我拥有的 2 个 excel 文件,但是当我放入第三个文件时,它会因该错误而崩溃。
c# - How to read(import) text from a .doc file using NPOI for .net
I am trying to do something so simple but I can not find a way for doing it.I have viewed the NPOI site few times but they have all kind of problem solvings except mine.I just want to load a .doc(MS Office Word 97-2003) document and get its text and then assign it to a string and use it.It sounds so simple but I just need someone to tell me or reference me to a source where I could get information about that.
excel - 将excel中的时间单元格读取为精确文本
我的time cell
excel 表中有一个自定义格式hh:mm
。在将它应用于任何公式时,它都将其视为 excel 为时间单元格保留的数值。
有没有办法将它作为文本检索?
目的是如果我 10:78
在这个时间单元格中输入它会自动转换为0.470833333
而不是触发验证或转换为 11:18。我只能设置自定义格式,因为我正在使用生成这个 excelNPOI
因此,如果我能够阅读我可以78
在数据验证公式中包含条件。我试过MINUTE()
但它返回18 instead of 78
我真的坚持这一点。任何帮助都应该给我很大的安慰。
vb.net - 使用 NPOI 库创建一个电子表格并让单元格具有彩色背景
我正在尝试使用 NPOI 库从 vb.net 应用程序创建 Excel 电子表格。我正在使用以下代码:
电子表格已创建,但单元格没有红色背景。如果我创建一个单元格并指定红色背景,但不向单元格写入任何内容,这似乎可行。关于如何执行此操作的文档似乎有限。有什么建议么?
谢谢