Previous Topic

Book Contents

Book Index

Next Topic

Multiple Resource Files in BIRT

Since BIRT 2.6 it is possible to define multiple resource files. This enables BIRT reports to have e.g. one file with overall labels/translations which will be used for all reports and other files which contain labels/translations which are specific for a particular report.

Example: Add additional resource file for the 'Services Catalog' Report

  1. Export the 'Service Catalog' report using the BIRT Report Customizer Dialog.
  2. Copy the report 'BIRT Report ServiceCatalog.rptdesign' into report project directory of the BIRT designer.
  3. Copy Valuemation translations directories (which contain entries necessary for the report) to report project directory
  4. Refresh report project in BIRT Designer

    In the standard report, the resource for this report is CrystalReportsLabelsText. Note that the “_en_US.properties” part is omitted. This allows generating the report in the language which is selected in Valuemation. If you use the German version, the report will be generated using the German resource files.

  5. Change the report. Use the Add File button to add 'crystalreports/CrystalReportsLabelsText_en_US.properties'. Remove 'CrystalReportsLabelsText'.

    Help Image

  6. Let's assume that it is the company policy for all reports to contain a confidentiality remark.
    This remark we want to save in an additional file containing such additional information:
    BIRT/BIRTReportsText_en_US.properties
    (Note: This is only for demonstration purposes, normally you would use the CrystalReportsLabelsText for this purpose)
  7. Using the Valuemation Rich client, add the following entries in the 'Translation for Application Text' catalog:
    • Basename: BIRT/BIRTReportsText
    • Language: English
    • Key: ServiceCatalog.confidential
    • Standard Translation: The content of this report is confidential!
    • Basename: BIRT/BIRTReportsText
    • Language: German
    • Key: ServiceCatalog.confidential
    • Standard Translation: Der Inhalt dieses Reports ist vertraulich!
  8. Restart Valuemation Rich Client.
  9. Copy the BIRT directory of the Valuemation Rich Client translation cache to the BIRT project directory.
  10. Refresh BIRT Project in the designer.
  11. Add the BIRT/BIRTReportsText_en_US.properties as an additional resource file.
  12. In the report, add an additional row in the grid below 'Service Catalog'.
  13. Add a label, select the localization tab for the label.
  14. Select textkey 'ServiceCatalog.confidential'

    Help Image

  15. Change Color 'Red' and set the font style to Bold on the 'General' properties tab.
  16. Save the report.
  17. In order to use multiple languages in Valuemation, you have to remove the '_en_US' part in the report design file. To do this, switch to the XML Source tab:

    Help Image

  18. Import the report into Valuemation.
  19. In the web.xml of the BIRT Report Server, set the BIRT_RESOURCE_FOLDER parameter to blank

    Help Image

  20. Restart the BIRT Report Server.

The new Report in English:

Help Image

If you switch the language in Valuemation to German and start the 'Print to BIRT' action again, a report in German will be generated:

Help Image

See Also

BIRT Reporting

Installation and Configuration

Integration of Birt Customizing

BIRT Report Based on XML from Valuemation

Problems & Solutions

Predefined Reports in Valuemation

BIRT with SOAP Webservice