Discussions
Categories
Groups
Community Home
Categories
INTERNAL ENABLEMENT
POPULAR
PUBLIC CLOUD
PRIVATE CLOUD
Quick Links
MY LINKS
HELPFUL TIPS
Back to website
Home
Intelligence (Analytics)
Internationalization problem when deploy
joseiru
Hi,
I am internationalizing all the labels in my project, it looks to work fine but when I deploy it I cannot see any of them. I am working with Tomcat and Birt 2.2
Can anybody tell me anything about this?
Thank you!
J.
Find more posts tagged with
Comments
joseiru
Does anybody hear about this problem? Because I have seen similar problems in other forums, but no solution.
Thank you very much!
J.
Dawton
I'm using resource file for labels and it works. We have very many property files in many folders in our application so I can hardly tell where to put your property file. But there is one important point:
Let's say that your resource file is called "myResources_en_US.properties". Use this name in designtime (just add it as report resource file) - it will be added without the extension - myResources_en_US
But in report runtime you must change the resourcefile name to its base form: "myResources" - without the language suffix. It will be automatically added by the application. I have found this hint somewhere on the net and it works.
joseiru
I have tried everything, and it does not work... i do not why it is not seeing the properties file.
I do not understand what you want to mean with this "But in report runtime you must change the resourcefile name to its base form: "myResources" - without the language suffix. It will be automatically added by the application. I have found this hint somewhere on the net and it works."
Thanks a lot.
J.
Dawton
With design time i mean designing & previewing report in e.g. eclipse. In design time I use full resource file name with english suffix.
With runtime i mean you use your report outside of the development tool. Before I deploy the report, I change the resource file name to the base form - myResources.
We use birt reports with our java application that connects to the birt report server and renders report to PDF for printing. I'm not sure if this is typical use of the birt report - but with this usecase it works as I described.
Anyway - the resource file is not part of the rptdesign file. You have e.g. resourcefiles like myResources_en_US.properties and myResources_de_DE.properties with english and german localization. You can attach only 1 resourcefile to the report - so you should specify the base name:
"myResources". Then, when you deploy the report, you must deploy also resource files (e.g. myResources_en_US.properties and myResources_de_DE.properties in our case). then, depending on locale selected in your application, the right resource file will be used to provide label localization when you display your report.
joseiru
I am sorry, but I have tried what you say and I do not get any label.
Thanks a lot!!!!
J.
Dawton
Our Java application has localization files in "propertiesresource" folder. Do you have something similar? maybe try just "properties" folder to put your property files here.....
joseiru
I continue with same problem.
Did anybody else fight with this thing?
Thank you!
J.
joseiru
I am opening the report inside a jsp page, and I am deploying in a Tomcat server... If somebody could help me, I would be very thankful.
Thanks a lot!
J.
indie
Hi,<br />
<br />
I guess we're having the same problem ... the reason is that tomcat usually doesn't unpack the deployed war file, and BIRT isn't finding the resources in the packed jar archive ...<br />
<br />
see my problem desc here:<br />
<a class='bbc_url' href='
http://www.birt-exchange.com/forum/designing-birt-reports/11992-setresourcepath-accessing-properties-file-jar.html'>http://www.birt-exchange.com/forum/designing-birt-reports/11992-setresourcepath-accessing-properties-file-jar.html</a><br
/>
<br />
could anyone help us on this issue???<br />
<br />
thx in advance!
joseiru
I have moved my project to birt 2.3 and I continue having the same problem.
Previewing the results works perfect, but when I deploy it in Tomcat, it does not see the resources file.
I would be very thankful if somebody can help me with this.
Regards.
J.
mwilliams
Hi joseiru,<br />
<br />
Are you using the BIRT viewer? If so, are you setting the BIRT_RESOURCE_PATH in the web.xml file?<br />
<br />
<pre class='_prettyXprint _lang-auto _linenums:0'>
<!-- Resource location directory. Default to ${birt home} -->
<context-param>
<param-name>BIRT_RESOURCE_PATH</param-name>
<param-value></param-value>
</context-param>
</pre>
<br />
If not, are you setting the config.setResourcePath()?