首先根据需求做个word文档,里面的一些信息是动态显示内容的(当然是空白的)。 然后另存为筛选过的网页(html),使用html文档代码建立一个jsp,在jsp里 加入 response.setContentType("application/msword"); response.setHeader("Content-disposition","attachment; filename=上门快捷工具.doc"); 或者 <%@ page contentType="application/msword; charset=gb2312" %> 访问这个jsp就是可以生成word了。