Skip to main content Skip to footer

GrapeCity ActiveReports Part 8: Localization Support

ActiveReports Script 8 – Localization Support

This is the 8th in a series of ActiveReports Blogs and is a continuation of:

Part 1 Getting StartedPart 2 Run a reportPart 3 Silverlight Viewer ToolbarPart 4 Uploading reports to Silverlight ViewerPart 5 Documentation TipsPart 6 Silverlight Viewer Theme CustomizationPart 7 PDF and Silverlight Printer Support

1) Japanese, Russian or Chinese are included with built in resources for ActiveReports. Other languages can be added as well. In the Solution Explorer, right-click the project file that you want to localize, and select Unload Project. This allows you to edit the file. The file name in Solution Explorer is appended with (unavailable). (Alternatively, you can edit the csproj or vbproj file in Notepad outside of Visual Studio)

clip_image002

2) Right-click the project file and select Edit SilverlightApplication1.csproj.

clip_image003

3) In the SupportedCultures node, add one or more locales that you want to use so that it looks like the following. There is no need to put in your Visual Studio default language.

zh-CN,ja-JP,ru-RU

4) When you have finished, right-click the project file in Solution Explorer, and select Reload Project.

5) In the MainPage.xaml.cs file, add code like the following to the MainPage class, changing the CultureInfo to the locale that you want to use…

System.Threading.Thread.CurrentThread.CurrentUICulture = new System.Globalization.CultureInfo("ja-JP");

clip_image005

6) Run the project to see the localized Silverlight Viewer. Hover over any of the Icons and see Japanese!

clip_image006

In Part 9 we will look at Silverlight Out of Browser support

Technorati Tags: ActiveReports,Getting started,grapecity,reporting components,DataDynamics,multi-part series,AR Tutorial,AR,AR Script,Tutorial,Script,part 6,license message,toolbar,documentation,help,metro,blend,Silverlight,themes,theme customization,contest,kindle Fire,printing,Silverlight API,PDF Print support,localization

tweetmeme_url = 'http://www.clubfarpoint.com/Forums/blogs/russells\_blog/archive/2012/01/17/grapecity-activereports-part-8-localization-support.aspx'; tweetmeme_source = '@russcamtv'; tweetmeme_hashtags = '#appdev';

MESCIUS inc.

comments powered by Disqus