By using this site you agree to the use of cookies for analytics and personalized content.
I agree Learn More
Articles
The technical articles cover a range of survey topics related to various features of Stimulsoft Reports. Interesting and useful tips, hints, how-tos, code snippets etc.

Reports Globalization

Share this post

Submit to FacebookSubmit to FacebookSubmit to TwitterSubmit to TwitterSubmit to GoogleSubmit to GoogleSubmit to LinkedInSubmit to LinkedInSubmit to VKSubmit to VK
If your firm is forced to create many similar reports, but in different languages, this article will definitely help you. You have probably already used to that if it comes to the crunch Stimulsoft is always happy to help. This issue is no exception. Stimulsoft Reports for solving such problems offers the Globalization Editor. With this editor it becomes possible to localize the report in several languages. The editor is easy to find, just follow the picture shown below:

19
WinForms Reports Designer (Office 2010 interface)


First, you must set the Auto Localize Report on Run property to Yes (this property is shown in the picture and described below). This allows checking the culture of the operating system.

Culture? Yes, the culture. Culture is an identifier of the language settings of your operating system. For example: Ru or En.

Finding the culture, the report generator checks cultures used in a report and are presented in the list. If identical cultures found, then all expressions in the report will be substituted. As a result, the report will be localized in the culture of the installed operating system, according to the parameters set in the Globalization Editor.

If culture of the operating system is not in the list of cultures used in the report, then the report will not be localized.

When set the Auto Localize Report on Run property to No, automatic localization will not work.

Let’s review the Globalization Editor:

20

1) The Add Culture button. Used to add a new culture selecting from a list of proposed cultures.

2) The Remove Culture button. Used to remove the selected culture.

3) The Close button. Used closes the Globalization Editor.

4) The Auto Localize Report on Run property, depending on the state, enables or disables report localization. If this property is set to Yes - localization is enabled, if to No - localization is disabled.

5) A list of cultures used in this report.

6) A list of components for localization.

What is globalization? This item is a list of all the major elements. By selecting one of the elements we associate with it the value of the crop.

7) Localization of the contents of the selected component.

8) A list of system variables, functions, formats of the report designer.

And now the most difficult, but interesting, especially for those who know and understand what is the project code. Dear programmers, the next part of this article is for you!

Report Globalization in Stimulsoft Reports:

For report globalization in Reports.Net it is necessary to call a special method before report rendering and displaying:

StiReport report = new StiReport();
string cultureName = "en";

report.LocalizeReport(cultureName);
report.Render(false);

report.LocalizeReport(cultureName);
report.Show();

cultureName - determines what language will be used in the globalization of the report. This culture should be defined in a report in the collection of globalization; otherwise globalization will not be performed.

For report globalization in Reports.Fx for Flex it is necessary to call a special method before report rendering and displaying:

var report: StiReport = new StiReport();
var cultureName: String = "en";

report.localizeReport(cultureName);
report.render(false);

report.localizeReport(cultureName);
report.show(); 

cultureName - determines what language will be used in the globalization of the report. This culture should be defined in a report in the collection of globalization; otherwise globalization will not be performed.

For report globalization in Reports.Fx for PHP it is necessary to set the value of globalization to GET or POST request when viewing the report:

http://localhost/stimulsoft/index.php?stimulsoft_client_key=ViewerFx&stimulsoft_report_key=Report.mrt&globalization=en

globalization - determines what language will be used in the globalization of the report. This culture should be defined in a report in the collection of globalization; or globalization will not be performed.

For report globalization in Reports.Fx for Java you must set the globalization parameter when viewing the report:

<stiviewerfx:button value="Show Report" report="Report.mrt" variableStr="globalization=en" />

globalization - determines what language will be used in the globalization of the report. This culture should be defined in a report in the collection of globalization, or globalization will not be realized.

Finally we want to give one advice. Would you like to have the best reports at the right time with minimum effort to create them? Use software from Stimulsoft Company. Would you like to be informed of all new products in the world of reporting? Visit our blog more often.
TwitterTwitterFacebookFacebookRSSRSSLinked inLinked inYoutubeYoutubeStimulsoft BlogStimulsoft BlogViberViberWhatsAppWhatsAppSkypeSkypeTelegramTelegram