You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@poi.apache.org by LiuGuoMing <gm...@sytdc.com> on 2006/05/15 10:24:44 UTC
HSSFWorkbook wb = new HSSFWorkbook()?
HI,ALL
HSSFWorkbook wb = new HSSFWorkbook();
HSSFSheet sheet = wb.createSheet("new sheet");
HSSFRow row = sheet.createRow((short)30);
HSSFCell cell = row.createCell((short)0);
cell.setEncoding(HSSFCell.ENCODING_UTF_16);
cell.setCellValue("111");
cell=row.createCell((short)1);
cell.setCellValue("222");
row.createCell((short)2).setCellValue("333");
row.createCell((short)3).setCellValue(true);
FileOutputStream fileOut = new
FileOutputStream("f:/mytest/workbook.xls",true); // why it is not save.
// FileOutputStream fileOut = new
FileOutputStream("f:/mytest/workbook.xls"); // it is save success.
wb.write(fileOut);
fileOut.close();
---------------------------------------------------------------------
To unsubscribe, e-mail: poi-user-unsubscribe@jakarta.apache.org
Mailing List: http://jakarta.apache.org/site/mail2.html#poi
The Apache Jakarta Poi Project: http://jakarta.apache.org/poi/