随笔分类 -  word

摘要:设置模板 /** *功能:导出xxx * *@param targetFilePath 目标路径 *@param templatePath 模板路径 *@param map 数据 *return File *throws IOException */ public File exportWord(S 阅读全文
posted @ 2020-09-16 16:43 790021521 阅读(438) 评论(0) 推荐(0)
摘要:一:导入aspose.words.jar 二:在word里要导出字段的位置,用书签标记,给一个key。将word放入需要获取模板的位置。 三: /** *功能:导出xxx * *@param targetFilePath 目标路径 *@param templatePath 模板路径 *@param 阅读全文
posted @ 2020-07-13 16:13 790021521 阅读(591) 评论(0) 推荐(0)
摘要:第一步:打开导入模板,加入占位符及添加图片占位 如图: 第二步:模板另存为xml格式;打开xml代码,修改关键位置的数据;主要是根据xml模板修改占位符${a.itemi},去掉其中多出来的部分。 修改后数据如图: list遍历循环输出的话要在每一行前后加上<#list 你的数据list as 转换 阅读全文
posted @ 2020-02-25 15:44 790021521 阅读(168) 评论(0) 推荐(0)
摘要://service层 /** *导入word **/ public JSONObject ImportWord(String fileType,String fileName, String title, ServiceRequest request) throws Exception; //imp 阅读全文
posted @ 2020-02-25 14:56 790021521 阅读(506) 评论(0) 推荐(0)