Search
Localization

You can localize the Spreadsheet to allow input data to be rendered correctly and you can localize the whole UI for a software that targets non-English speaking audience.

Localizing the Spreadsheet to Render Correctly Data

In this case you will populate the cells of the Worksheet with text that does not use (only) the English alphabet. Use the Locale property to specify a different CultureInfo.

The following example specifies that a Workbook would show data in Korean:

C#  Copy Code

workbook.Locale = new CultureInfo("ko-KR");

Keep in mind that not all FontType-s would be compatible with the language you want to use. Make sure you set as a default Font one that does support your chosen language:

C#  Copy Code

//create a global styling for the whole sheet
var globalStyle = activeSheet.CellRanges[0, 0, activeSheet.Columns.Count - 1, activeSheet.Rows.Count - 1].Style;
globalStyle.FontName = "Malgun Gothic";

 Note

By default the Spreadsheet component uses the default CultureInfo of your operating system rather than English.

Localizing the UI

You can render the UI of the spreadsheet as well the auxiliary forms that can be shown in a language of your choice. The component supports localization of the UI through XML files. Ready-to-use XML files for 7 popular languages: French, German, Spanish, Portuguese, Korean, Chinese and Russian  can be found in the Localization sub-folder in the installation folder of the control. Use them to create a XML file with the language of your choice.

The following code loads the Korean localization file, which would be used by the UI of the application:

C#  Copy Code

var file = @"../../Localization/Localization.KO.xml";
  if (file != null && File.Exists(file))
       workbook.SetLocalizationInfo(file);


The result: