将现有Excel电子表格中的程式化邮件合并样式数据注入? [英] Programmatic mail-merge style data injection into existing Excel spreadsheets?

查看:133
本文介绍了将现有Excel电子表格中的程式化邮件合并样式数据注入?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我想自动化数据输入到Excel电子表格。用户数据将存在于网站上,当用户请求时,该数据将需要注入到Excel电子表格中。复杂的是,Excel电子表格的格式在用户之间可能会有很大的不同 - 它将被用户定义。

I'd like to automate data entry into Excel spreadsheets. User data will exist on a web site, and when the user requests it, that data will need to be injected into an Excel spreadsheet. The complication is that the format of the Excel spreadsheet can vary significantly between users - it'll be user defined.

我一直在想这是模板问题 - excel电子表格提供了模板,任务是将数据注入该模板中的特定用户定义的单元格。

I've been thinking of this as a templating problem - the excel spreadsheet provides the template, and the task s to inject data into specific user defined cells within that template.

我已经看过xlwt和xlrd for python,as以及jexcelapi和POI-HSSF for Java。他们似乎可以工作,但是考虑到我只是想将价值观放在某些细胞中,它们似乎是过度杀伤力的。我也担心在处理之后重写用户的电子表格;似乎是一个向进程中引入错误的机会。

I've looked at xlwt and xlrd for python, as well as jexcelapi and POI-HSSF for Java. They seem like they could work, but given that I simply want to put values into certain cells, they seem like overkill. I'm also worried about re-writing the user's spreadsheet after processing; seems like an opportunity to introduce errors into the process.

有没有办法告诉excel将数据从一张表合并到另一张?我想我可以生成一个只有数据的简单电子表格,并以某种方式让Excel将其合并到用户现有的电子表格中。

Is there a way to tell excel to merge the data from one sheet into another? I'm thinking I could produce a simple spreadsheet that has only the data, and somehow get Excel to merge it into the user's existing spreadsheet.

有意义吗?更好的方法?

Make sense? Better approaches?

推荐答案

jXLS也许是一个选择。您将XLS文件定义为模板,然后合并数据。

jXLS is maybe an option. You define an XLS file as a template and then you merge your data.

快速概述 here < a>

Quick overview here

http://jxls.sourceforge.net/

这篇关于将现有Excel电子表格中的程式化邮件合并样式数据注入?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆