做策划的网站推广,手机网址大全123客户端下载,如何登录微信公众号管理平台,那些网站做任务能赚钱WeihanLi.Npoi 1.20.0 ReleasedIntroWeihanLi.Npoi 是一个基于 netstandard2.0 的一个 NPOI 扩展库#xff0c;主要用于导入导出 Excel 以及CSV#xff0c;支持通过 Fluent API 的方式来支持非常灵活的导入导出配置#xff0c;详细使用可以参考文档介绍以及项目示例Updates最… WeihanLi.Npoi 1.20.0 ReleasedIntroWeihanLi.Npoi 是一个基于 netstandard2.0 的一个 NPOI 扩展库主要用于导入导出 Excel 以及CSV支持通过 Fluent API 的方式来支持非常灵活的导入导出配置详细使用可以参考文档介绍以及项目示例Updates最近我自己没什么更新主要是一个外国小哥提了三个 PR主要改进了 Excel 文件导入成一个 DataTable对应的 API 是 ExcelHelper.ToDataTable最近针对 DataTable 的改进都是基于导入一个别的地方生成的一个 excel 文件如果你是 DataTable 使用这个库导出的话再导入是不会有问题的主要更新如下Bug fix:修复导入的 Excel 文件表头单元格格式不是 string 时数据处理异常的 BUG https://github.com/WeihanLi/WeihanLi.Npoi/pull/120修复导入的 Excel 文件存在空列时可能会导致数据不对的 BUG https://github.com/WeihanLi/WeihanLi.Npoi/pull/118Features:ExcelHelper.ToDataTable API 增加 bool removeEmptyRows false, int? maxColumns null 参数支持移除空行和指定最大导入行数https://github.com/WeihanLi/WeihanLi.Npoi/pull/123DataTable ToDataTable(byte[] excelBytes, ExcelFormat excelFormat, bool removeEmptyRows false, int? maxColumns default);DataTable ToDataTable(byte[] excelBytes, ExcelFormat excelFormat, int sheetIndex, bool removeEmptyRows false, int? maxColumns default);DataTable ToDataTable(string excelPath, int sheetIndex, int headerRowIndex, bool removeEmptyRows false, int? maxColumns default);
作为对于 1.18.0 版本中引入的 MappingProfile feature 的改进可以参考 WeihanLi.Npoi 1.18.0 Released增加了几个 API 来简化 MappingProfiler 的注册FluentSettings.LoadMappingProfileTestEntity, TestEntityExcelMappingProfile();FluentSettings.LoadMappingProfileTestEntityExcelMappingProfile();FluentSettings.LoadMappingProfile(new TestEntityExcelMappingProfile());
More看提 PR 小哥的 Github 资料是来自捷克共和国布拉格的一位工程师小哥非常认真提交的每一个 PR 都对应提供了完善的单元测试用例真的非常赞为小哥点赞 :thumbsup:感谢小哥的贡献我们如果在对开源项目做贡献的时候应该向这位小哥学习也应该尽可能地在修复 BUG 或者贡献新功能的同时提供对应的测试用例以构建更为健壮和高质量的开源项目Referenceshttps://github.com/WeihanLi/WeihanLi.Npoihttps://weihanli.github.io/WeihanLi.Npoi/index.htmlhttps://weihanli.github.io/WeihanLi.Npoi/docs/articles/intro.htmlhttps://github.com/WeihanLi/WeihanLi.Npoi/pull/118https://github.com/WeihanLi/WeihanLi.Npoi/pull/120https://github.com/WeihanLi/WeihanLi.Npoi/pull/123WeihanLi.Npoi 1.18.0 Released