response.setContentType("application/vnd.ms-excel;charset=GBK");
private static HSSFWorkbook readFile(String filename){
try {
wb = new HSSFWorkbook(new FileInputStream(filename));
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
return wb;
}
两种jar包 jxl 和 apache的集成开源 写入文件或者直接保存