代码大同小异,
StringBuffer sb = new StringBuffer(50);
sb.append("attachment; filename="+filename+".csv");
commonEntity.getResponse().setContentType("application/octet-stream;charset=Windows-31J");
commonEntity.getResponse().setHeader("Content-Disposition",sb.toString());fis = new BufferedInputStream(new FileInputStream(path+ "\\"+ inputForm.getTmpFileName()));
bos = new BufferedOutputStream(getResponse().getOutputStream());......
大概就是这样
StringBuffer sb = new StringBuffer(50);
sb.append("attachment; filename="+filename+".csv");
commonEntity.getResponse().setContentType("application/octet-stream;charset=Windows-31J");
commonEntity.getResponse().setHeader("Content-Disposition",sb.toString());fis = new BufferedInputStream(new FileInputStream(path+ "\\"+ inputForm.getTmpFileName()));
bos = new BufferedOutputStream(getResponse().getOutputStream());......
大概就是这样
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货