formats = new WritableCellFormat[config.length]; 是这种形式的
if( i==0 || i==1){columnWidth[i] =10;
config[i].put("alignment", 2);
config[i].put("type", "number");
config[i].put("numberFormat", "#0.00%");
我如果想输出百分数,写成"#0.00%" 可以吗?
我不清楚你程序到底是怎么创建WritableCellFormat的,如果你设置成#0.00%,到最终如果是new WritableCellFormat(NumberFormats.PERCENT_FLOAT)的话就能。