from :XSSFClientAnchor_朕的爱妃呢的博客-CSDN博客
XSSFClientAnchor参数的含义
用到poi的导出,看到这么多参数一时有些迷糊。
XSSFClientAnchor
(int dx1, int dy1, int dx2, int dy2, int col1, int row1, int col2, int row2)
前四个还不知道有什么作用,知道的欢迎评论区指导
col1 :从左向右数 | 的线(从0)
row1 :从上到下数 —— 的线(从0)
col2 :同col1
row2 :同row1
col1 和 row1 代表左上坐标。
col2 和 row2 代表右下坐标。
中间的范围就是要写入的地方。
XSSFClientAnchor anchor = new XSSFClientAnchor(0, 0, 0, 0, 2, 3, 3, 4);
左上坐标:
右下坐标: