publicStringwriteToExcelFormat(ListrecordList,String[]title,String[]fmtCell)throwsException{//列格式分解类型:列宽intfmtMax=fmtCell.length;String[][]fmtColumn=newString[fm...
public String writeToExcelFormat(List recordList, String[] title,
String[] fmtCell) throws Exception {
// 列格式分解 类型:列宽
int fmtMax = fmtCell.length;
String[][] fmtColumn = new String[fmtMax][2];
for (int i = 0; i < fmtMax; i++) {
// 初始化
fmtColumn[i][0] = "";
fmtColumn[i][1] = "";
// 分解格式
if (!fmtCell[i].equals("")) {
String[] a = fmtCell[i].split(":");
for (int j = 0; j < a.length; j++) {
fmtColumn[i][j] = a[j];
}
}
}
// 生成随机数文件名
String filePath = getRandomFilePath();
// 打开文件
Fi