easyexcel
easyexcel copied to clipboard
【疑问】官方文档中写入批注,必须使用内存模式,实际使用过程中并不需要
插入批注官方文档中代码
@Test
public void commentWrite() {
String fileName = TestFileUtil.getPath() + "commentWrite" + System.currentTimeMillis() + ".xlsx";
// 这里 需要指定写用哪个class去写,然后写到第一个sheet,名字为模板 然后文件流会自动关闭
// 这里要注意inMemory 要设置为true,才能支持批注。目前没有好的办法解决 不在内存处理批注。这个需要自己选择。
EasyExcel.write(fileName, DemoData.class).inMemory(Boolean.TRUE).registerWriteHandler(new CommentWriteHandler())
.sheet("模板").doWrite(data());
}
问题描述
easyexcel 3.3.3版本,在实际使用过程中并未设置使用内存模式inMemory(Boolean.TRUE),依然可以插入批注,请问是此限制已经解决,文档未及时更新的原因吗?