Home
Designing Analytics Reports
Report engine seems to ignore __locale
Migrateduser
<p>Hi,</p>
<p>I have to make a report multi-lingual. If I run the report in the designer and set the __locale parameter to various languages, everything works as expected - BIRT finds the language resource property files, dates get formatted according to the locale, etc.</p>
<p>However, when I run the same report on our server, passing a __locale parameter, the locale doesn't change. I put this script into the Report Design > Initialize script to see what's going on:</p>
<pre class="_prettyXprint">
importPackage(Packages.java.lang);
locale = reportContext.getLocale();
lang = locale.getLanguage();
country = locale.getCountry();
System.out.println("lang:" + lang);
System.out.println("country:" + country);
System.out.println("__locale:" + params["__locale"].value);</pre>
<p>Output:</p>
<pre class="_prettyXprint">
lang:en
country:US
__locale:fr_FR</pre>
<p>So, the report receives the __locale parameter, but chooses to ignore it! Any ideas?</p>
<p> </p>
<p>Thanks,</p>
<p>Tim</p>
<p> </p>
<p>
</p>
<p> </p>
Find more posts tagged with
Comments
There are no comments yet