在IReport中设置REPORT_LOCALE? [英] Setting REPORT_LOCALE in IReport?
本文介绍了在IReport中设置REPORT_LOCALE?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
是否可以通过Scriptlet或直接在IReports中覆盖Param REPORT_LOCALE?
Is it possible to overwrite the Param REPORT_LOCALE via Scriptlet, or directly in IReports ?
Pseudocode:
Pseudocode:
if($P{MYLOCALEPARAM}== 1) REPORT_LOCALE = "en_US";
if($P{MYLOCALEPARAM}== 2) REPORT_LOCALE = "de_GE";
....
我通过
"RunJasper.jar"
(gtwebmarque.com)
通过PHP exec我不愿意改变并重新编译这个工具......
via PHP exec and i am loath to change and recompile this tool ...
我知道在IReport中有一些本地化选项选项选项卡。
但是我想动态地实现它
I know that there are some localisation Options in IReport Options Tabs. But i would like to implement it dynamicly
BR Christian
BR Christian
推荐答案
您可以借助 JasperReports API 设置区域设置。
You can set locale with help of JasperReports API.
样本:
Map params = new HashMap();
params.put(JRParameter.REPORT_LOCALE, Locale.US);
JasperFillManager.fillReportToFile(compiledReportName, params);
这篇关于在IReport中设置REPORT_LOCALE?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文