开发者社区> 问答> 正文

java输入流问题

我有好几个方法每个里面都用到了sc.write(s);这个写入的方法,我在主函数里调用这些方法,结果报出:
Exception in thread "main" org.apache.poi.openxml4j.exceptions.OpenXML4JRuntimeException: Fail to save: an error occurs while saving the package : The part /docProps/app.xml fail to be saved in the stream with marshaller org.apache.poi.openxml4j.opc.internal.marshallers.DefaultMarshaller@4fbf1942

at org.apache.poi.openxml4j.opc.ZipPackage.saveImpl(ZipPackage.java:503)
at org.apache.poi.openxml4j.opc.OPCPackage.save(OPCPackage.java:1467)
at org.apache.poi.POIXMLDocument.write(POIXMLDocument.java:217)
at test.UseProcess.UseProcessSum(UseProcess.java:198)
at test.TestMain.main(TestMain.java:42)
Caused by: org.apache.poi.openxml4j.exceptions.OpenXML4JException: The part /docProps/app.xml fail to be saved in the stream with marshaller org.apache.poi.openxml4j.opc.internal.marshallers.DefaultMarshaller@4fbf1942
at org.apache.poi.openxml4j.opc.ZipPackage.saveImpl(ZipPackage.java:494)
... 4 more

我只执行一个方法就没事,我该怎么办啊?

展开
收起
WM云建站 2016-02-17 22:46:13 9042 0
2 条回答
写回答
取消 提交回答
  • github.com/xuri

    推荐一个功能丰富、兼容性好、高性能的 Excel 文档基础库 Excelize: https://github.com/xuri/excelize

    2021-01-21 13:24:08
    赞同 1 展开评论 打赏
  • 我说我不帅他们就打我,还说我虚伪

    `at test.UseProcess.UseProcessSum(UseProcess.java:198)
    at test.TestMain.main(TestMain.java:42)`
    看看这两行代码有没有问题,最好把代码贴出来看看。

    2019-07-17 18:29:20
    赞同 展开评论 打赏
问答分类:
问答标签:
问答地址:
问答排行榜
最热
最新

相关电子书

更多
Spring Cloud Alibaba - 重新定义 Java Cloud-Native 立即下载
The Reactive Cloud Native Arch 立即下载
JAVA开发手册1.5.0 立即下载