Skip to main content

Hi,

I am using the DevExpress report application provided by thinkwise. I want to localize my report so I can export it in multiple languages. The report is for invoices.

I found this link in the docs: https://docs.devexpress.com/XtraReports/401573/detailed-guide-to-devexpress-reporting/globalize-and-localize-reports/localize-reports

However I cannot find this option in the devexpress provided by ThinkWise. Any suggestions on how to achieve localization?

Hi,

I also don't see this available in the TSF DevExpress Report Designer. An alternative way could be to either create a Textbox for every language per field and suppressing those fields based on which language is given via a parameter, or another way is by (almost) completely formatting the Report in your end product in a HTML document, then transferring that in a parameter to the report and showing that. That does mean all translations have to be given in the HTML.

Sounds like a good idea, feel free to create it! I do think more fellow Community members can use this.


@pvleeuwen I haven't been able to find the Idea yet, feel free to create one as this topic is not suitable to be converted to an Idea. Please create a reply with a link to the idea and mark it as Best answer. Thanks!


Hi,

I also don't see this available in the TSF DevExpress Report Designer. An alternative way could be to either create a Textbox for every language per field and suppressing those fields based on which language is given via a parameter….”

The solution we use is a variation of the first alternative. We have placed text boxes for each label containing a field from a view. With this view we make sure that we have the language-dependent label texts available.
In this way, the translations are available in multiple reports and are easy to maintain.


I found a way to do the translation of labels with the localization option in devexpress. 
In the report in the option pane (screen shot) under design there is an option called Localization.


There you can translate the labels for different languages.

The example report contains a parameter with the selected language that must be used.


This parameter is used in the script section(beforeprint method) to apply the selected language.
(Screen shot)
 

 


Code part:

using System.Globalization;
using DevExpress.XtraReports.UI;

private void Report1_BeforePrint(object sender, System.ComponentModel.CancelEventArgs e) {
    if (Parametersr"lang"] != null){   
        ApplyLocalization(Parametersr"lang"].Value.ToString());
    }    
}
 


Reply