乔山办公网我们一直在努力
您的位置:乔山办公网 > excel表格制作 > 如何在<em>poi</em>中设定<em>excel</em>的指定行

如何在<em>poi</em>中设定<em>excel</em>的指定行

作者:乔山办公网日期:

返回目录:excel表格制作


HSSFWorkbook wb = new HSSFWorkbook();
zhidao HSSFSheet sheet = wb.createSheet("new sheet");

HSSFRow row = sheet.createRow((short) 1);
HSSFCell cell = row.createCell((short) 1);

HSSFRichTextString content = new HSSFRichTextString("This is a test of message");
cell.setCellValue(content);

sheet.addMergedRegion(new Region(1,(short)1,1,(short)2));

FileOutputStream fileOut = new FileOutputStream("d:/Demo_02_05.xls");
wb.write(fileOut);
fileOut.close();

貌似zhidao现在的POI还无法实现你这个要求
如果是删除行的话可以用:
XSSFSheet xs = xwb.createSheet(sheetName);
XSSFRow yRow = xs.createRow(row);
xs.removeRow(yRow);
李煜《相见欢无言独上西楼》剪不断、理还乱,是离愁。别是一番滋味在心头。

sheet.setRowSumsBelow(false);
sheet.setRowSumsRight(false);

相关阅读

  • 用Java的<em>POI</em>包读取<em>Excel</em>的

  • 乔山办公网excel表格制作
  • 这是正常的。通过POI取出的百数值默认都是double,即使excel单元格度中存的是问1,取出来的值也是1.0,这就造成了一些问题,如果数据库字段是int,那么就会wrongdatatype,所以答需要对数
关键词不能为空
极力推荐
  • <em>excel</em>中怎么<em>数字组合</em>-excel

  • 软件版本:Office2007方法如下:1.在A列中随机用0-9组成十个五位数,输入公式如下:2.下拉填充到十个单元格中,就得到了随机组成的十个五位数:excel怎么组合数字" src="/uploads/tu/203.jpg

ppt怎么做_excel表格制作_office365_word文档_365办公网