New to Telerik UI for ASP.NET AJAX? Download free 30-day trial

Localization

  • Show/Hide Border
  • Table Properties
  • Delete Table
  • Row
    • Insert Row Above
    • Insert Row Below
    • Delete Row
  • Column
    • Insert Column to the Left
    • Insert Column to the Right
    • Delete Column
  • Cell
    • Merge Cells Horizontally
    • Merge Cells Vertically
    • Split Cell Horizontally
    • Split Cell Vertically
    • Delete Cell
  • Cell Properties
  • Table Properties
  • Properties...
  • Image Map Editor
  • Properties...
  • OpenLink
  • Remove Link
  • Insert Select
  • Cut
  • Copy
  • Paste
  • Paste from Word
  • Paste Plain Text
  • Paste As Html
  • Paste Html
  • Demo Configurator
Choose Language
External Localization

With RadEditor you can easily create a new language pack or alter some of the labels of an existing one.

Localization is contained in resourse files .resx which are within the product dll. There are three built-in localizations (English, French and German) which can be set through the Language property. For example to localize the editor in German set Language="de-DE".

To create your own localizations for the editor, you need to create the  App_Global Resources folder in the root of your web application and copy the English resx files (which will be provided for download from our site) into it. These files are:

  • RadEditor.Dialogs.resx - contains all dialogs' localization strings
  • RadEditor.Main.resx - contains the spell's, paste and other localization strings
  • RadEditor.Modules.resx - contains the modules' localization strings
  • RadEditor.Tools.resx - contains the editor's tools localization strings

After you have copied the resx files, you must duplicate each copy of these files and rename them using the syntax shown in the few examples below:

  • RadEditor.Tools.<Your_Language>.resx
  • RadEditor.Main.<Your_Language>.resx
  • RadEditor.Dialogs.<Your_Language>.resx
  • RadEditor.Tools.<You_Language>.resx

All resx file contain two columns: Name and Value.

It is mandatory to set the ReservedResource string in the Name column of the RadEditor.Tools.<Language>.resx file. Without this string the resource files will not be recognized.

Once you do that you can localize the strings in the Value column. You need to localize the strings in the Value column of your new resx files.

The next step is to set the Language property of RadEditor to the name of the <localization> string in the RadEditor.Tools.<language>.resx file:

Inline in the RadEditor's declaration:

<telerik:radeditor runat="server" ID="RadEditor1" Language="it-IT"></telerik:radeditor>

In the CodeBehind:

C#:
RadEditor1.Language = "it-IT";

VB.NET:
RadEditor1.Language = "it-IT"

If you provide a new localization for RadEditor which works properly, we will gladly reward you for your work.

 

Changing the location of the Localization files

The LocalizationPath property indicates where the editor will look for its .resx localization files in the web application. By default the .resx localization files of RadEditor are placed in the App_GlobalResources folder. However, if it is not possible to put the resource files in the default location or .resx files compilation is disabled for some reason (e.g. in a DotNetNuke environment), then the LocalizationPath property should be set to point to the new location of the resource files.

All labels, buttons, tooltips and error messages are located in external resx resource files, so that the language of the editor can be switched with a single property (Language). By default, the resx files are located in the App_GlobalResources folder. To load the localization files from another directory, set the LocalizationPath property to point to the new folder location.

Related Resources

  • DefaultCS.aspx
  • DefaultCS.aspx.cs
<%@ Page Language="C#" Theme="Default" AutoEventWireup="true" CodeFile="DefaultCS.aspx.cs"Inherits="Telerik.Web.Examples.Editor.Localization.DefaultCS"  %>

<%@ Register TagPrefix="qsf" Namespace="Telerik.QuickStart" %>
<%@ Register TagPrefix="telerik" Namespace="Telerik.Web.UI" Assembly="Telerik.Web.UI" %>
<!DOCTYPE html>
<html xmlns='http://www.w3.org/1999/xhtml'>
<head runat="server">
    <title>Telerik ASP.NET Example</title>
<link href="../Common/styles.css" rel="stylesheet" type="text/css" />
</head>
<body>
    <form id="form1" runat="server">
    <telerik:RadScriptManager runat="server" ID="RadScriptManager1" />
    <telerik:RadSkinManager ID="RadSkinManager1" runat="server" ShowChooser="true" />
    <div class="demo-containers">
        <div class="demo-container">
            <telerik:RadEditor RenderMode="Lightweight" runat="server" ID="RadEditor1" SkinID="DefaultSetOfTools">
            </telerik:RadEditor>
        </div>
    </div>

    <telerik:RadAjaxManager runat="server">
        <AjaxSettings>
            <telerik:AjaxSetting AjaxControlID="RadioButtonListLanguage">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadEditor1" LoadingPanelID="LoadingPanel1"/>
                    <telerik:AjaxUpdatedControl ControlID="RadioButtonListLanguage" />
                </UpdatedControls>
            </telerik:AjaxSetting>
            <telerik:AjaxSetting AjaxControlID="LocalizationPathCheckBox">
                <UpdatedControls>
                    <telerik:AjaxUpdatedControl ControlID="RadEditor1" LoadingPanelID="LoadingPanel1"/>
                    <telerik:AjaxUpdatedControl ControlID="RadioButtonListLanguage" />
                    <telerik:AjaxUpdatedControl ControlID="LocalizationPathCheckBox" />
                </UpdatedControls>
            </telerik:AjaxSetting>
        </AjaxSettings>
    </telerik:RadAjaxManager>

    <telerik:RadAjaxLoadingPanel runat="server" ID="LoadingPanel1"></telerik:RadAjaxLoadingPanel>

    <qsf:ConfiguratorPanel runat="server">
        <Views>
            <qsf:View>
                <qsf:ConfiguratorColumn runat="server" Title="Choose Language" Size="Narrow">
                    <qsf:RadioButtonList ID="RadioButtonListLanguage"
                        runat="server" AutoPostBack="True" OnSelectedIndexChanged="RadioButtonListLanguage_SelectedIndexChanged">
                        <asp:ListItem Value="en-US" Selected="True">English (en-US)</asp:ListItem>
                        <asp:ListItem Value="de-DE">Deutsch (de-DE)</asp:ListItem>
                        <asp:ListItem Value="fr-FR">Francais (fr-FR)</asp:ListItem>
                    </qsf:RadioButtonList>

                </qsf:ConfiguratorColumn>

                <qsf:ConfiguratorColumn runat="server" Title="External Localization" Size="Medium">
                        <asp:CheckBox ID="LocalizationPathCheckBox" runat="server" Text="~/Editor/Examples/Localization/Resources"
                            OnCheckedChanged="LocalizationPathCheckBox_CheckedChanged" AutoPostBack="true"></asp:CheckBox>
                </qsf:ConfiguratorColumn>
            </qsf:View>
        </Views>
    </qsf:ConfiguratorPanel>
    </form>
</body>
</html>

Support & Learning Resources

Find Assistance