| | |
| | | sheet1.createRow(rownum); |
| | | sheet1.getRow(rownum).createCell(1).setCellValue(picName[i]); |
| | | rownum++; |
| | | HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 512, 255,(short) 1, rownum, (short) 10, 25 * (picnum + 1)); |
| | | XSSFClientAnchor anchor = new XSSFClientAnchor(0, 0, 512, 255,(short) 1, rownum, (short) 10, 25 * (picnum + 1)); |
| | | anchor.setAnchorType(3); |
| | | patriarch.createPicture(anchor,wb.addPicture(bytes.get(picnum),HSSFWorkbook.PICTURE_TYPE_PNG)).resize(1); |
| | | picnum ++;rownum+=25; |
| | |
| | | |
| | | //插入对比图片 |
| | | int picNum = 0; |
| | | HSSFClientAnchor anchor = new HSSFClientAnchor(0, 0, 512, 255,(short) 0, rowNum, (short) 10, rowNum+25); |
| | | XSSFClientAnchor anchor = new XSSFClientAnchor(0, 0, 512, 255,(short) 0, rowNum, (short) 10, rowNum+25); |
| | | anchor.setAnchorType(3); |
| | | patriarch.createPicture(anchor,wb.addPicture(bytes.get(picNum),HSSFWorkbook.PICTURE_TYPE_PNG)).resize(1); |
| | | picNum ++;rowNum+=25; |
| | |
| | | cell1.setCellStyle(cellStyle); |
| | | |
| | | //插入对比图片 |
| | | HSSFClientAnchor anchor1 = new HSSFClientAnchor(0, 0, 512, 255,(short) 0, rowNum1, (short) 10, rowNum1+25); |
| | | XSSFClientAnchor anchor1 = new XSSFClientAnchor(0, 0, 512, 255,(short) 0, rowNum1, (short) 10, rowNum1+25); |
| | | anchor1.setAnchorType(3); |
| | | patriarch1.createPicture(anchor1,wb.addPicture(bytes.get(picNum),HSSFWorkbook.PICTURE_TYPE_PNG)).resize(1); |
| | | rowNum1+=25; |