GcExcel打开文件报错
本帖最后由 Richard.Huang 于 2024-4-29 13:57 编辑产品:GcExcel
版本:6.2.5
调研编号:DOCXLS-9951
LastReview:2024/04/29
该问题已经在V7.0.5中得到修复,可以通过升级版本来解决该问题
public static void main(String[] args) {
String path = "L:\\下载文件\\6001-0004-0001-主营业务收入匡算 (1).xlsx";
try {
Workbook workbook = new Workbook();
workbook.open(path);
System.out.println();
} catch (Exception e) {
e.printStackTrace();
}
}
17:41:31.748 DEBUG -1 Get instance of MypdfGraphics(New): com.grapecity.documents.excel.bH@53f4836817:41:32.397 DEBUG -1 Item with same key has already been added.17:41:32.397 DEBUG -1 java.lang.IllegalArgumentException: Item with same key has already been added.java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Item with same key has already been added. at com.grapecity.documents.excel.p.c.J.a(Unknown Source) ~ at com.grapecity.documents.excel.p.c.J.a(Unknown Source) at com.grapecity.documents.excel.Workbook.a(Unknown Source) at com.grapecity.documents.excel.Workbook.a(Unknown Source) at com.grapecity.documents.excel.Workbook.open(Unknown Source) at com.grapecity.documents.excel.Workbook.open(Unknown Source) at cn.com.bdo.dgCenter.service.GcExcelService.main(GcExcelService.java:3331) Caused by: java.lang.IllegalArgumentException: Item with same key has already been added. at com.grapecity.documents.excel.l.b.a(Unknown Source) ~ at com.grapecity.documents.excel.p.c.u.a(Unknown Source) ~ at com.grapecity.documents.excel.p.c.u.a(Unknown Source) ~ at com.grapecity.documents.excel.p.c.J.a(Unknown Source) ~ ... 7 morejava.lang.IllegalArgumentException: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Item with same key has already been added. at com.grapecity.documents.excel.p.c.J.a(Unknown Source) at com.grapecity.documents.excel.Workbook.a(Unknown Source) at com.grapecity.documents.excel.Workbook.a(Unknown Source) at com.grapecity.documents.excel.Workbook.open(Unknown Source) at com.grapecity.documents.excel.Workbook.open(Unknown Source) at cn.com.bdo.dgCenter.service.GcExcelService.main(GcExcelService.java:3331)Caused by: java.lang.IllegalArgumentException: java.lang.IllegalArgumentException: Item with same key has already been added. at com.grapecity.documents.excel.p.c.J.a(Unknown Source) ... 6 moreCaused by: java.lang.IllegalArgumentException: Item with same key has already been added. at com.grapecity.documents.excel.l.b.a(Unknown Source) at com.grapecity.documents.excel.p.c.u.a(Unknown Source) at com.grapecity.documents.excel.p.c.u.a(Unknown Source) at com.grapecity.documents.excel.p.c.J.a(Unknown Source) ... 7 moreDisconnected from the target VM, address: '127.0.0.1:58078', transport: 'socket'
您好,
问题已复现,已将此问题记录下来进一步调研具体原因,待有进展贴中通知您。 更新进展:
此问题计划在V7.0.5修复,届时将不会抛出异常,待版本发布后您可以升级验证下。 最新调研进展:本贴中提及的问题已经在GcExcelV7.0.5中得到优化,新版本已经发布,您可以通过升级GcExcel的版本来解决该问题,本贴就先结帖了,后续有其他相关问题,欢迎发新帖询问
页:
[1]