PIO打印问题!
HSSFWorkbook wookbook = null;
HSSFSheet sheet = null;
HSSFRow row = null;
HSSFCell cell = null;
wookbook = new HSSFWorkbook();
sheet = wookbook.createSheet();
question 1:
-------------------------------------------------------------------
//设置列宽
//???假如只有5列,如何不显示其他所有的列呢?也就说只显示我需要的5列。
for (int i = 0; i <= icolumn; i++){
if (i == 0||i==4) {
sheet.setColumnWidth((short)i,((short)500));
}else{
sheet.setColumnWidth((short)i,((short)5000));
}
}
------------------------------------------------------------------
question 2:
---------------------------------------------------------------
//?如何合并单位格?这一行我只要一列即row.createCell((short)3);其他列都合并掉?
row = sheet.createRow((short)0);
cell = row.createCell((short)3);
---------------------------------------------------------------