如何删除 POI 生成的 Excel 中的警告?

2024-04-13

I am using Apache POI for writing content into excel sheet. after generating an excel in all the cells which ever cell has numbers, it contains one blue mark(each cells left top corner). its like a warning. how can i remove them while writing the content to excel? PFA screen shot.enter image description here

Thanks!


您可以尝试设置单元格类型:

HSSFCell cell = row1.createCell(i);
cell.setCellType(Cell.CELL_TYPE_STRING); // =0, or Cell.CELL_TYPE_NUMERIC = 1
cell.setCellValue(value);

See the API docs http://poi.apache.org/apidocs/org/apache/poi/hssf/usermodel/HSSFCell.html#setCellType%28int%29了解更多信息。

本文内容由网友自发贡献,版权归原作者所有,本站不承担相应法律责任。如您发现有涉嫌抄袭侵权的内容,请联系:hwhale#tublm.com(使用前将#替换为@)

如何删除 POI 生成的 Excel 中的警告? 的相关文章

随机推荐