The requested page is not available for the requested platform. You are viewing the content for Default platform.

How to: Add a Custom Localization Dictionary to a Mobile Application

  • 2 min to read

The Localization Module includes built-in DevExtreme localization dictionaries used to localize widgets in your application to de, en, ja and ru languages. This topic describes how to create a new localization dictionary and apply it to your application. Note that you can use the approach described below to modify an existing dictionary.

  • In your Mobile resources storage's modules folder, create a new subfolder and name it "localization".
  • Create a copy of the devextreme_en.json file that is generated automatically on the first application start in the MySolution\MySolution.Mobile\resourcescache\modules\localization cache folder (refer to the Localization Module Overview topic's Localization Resources Cache section to learn more about localization files' cache in Mobile applications).
  • Include this file in your Mobile project.

    IncludeInProject_LocalizationDictionary

  • In this new file name, replace the "en" localization identifier with a target language identifier and remove the "devextreme" prefix. For example, the localization dictionary name for Spanish should be "es.json".
  • Open the new file. Replace the "en" localization identifier with a target language identifier and fill this file with localized values.

    {
        "es": {
            "Yes": "Si",
            "No": "No",
            "Cancel": "Cancelar",
            // ...
        }
    }
    

Learn more about DevExtreme localization resources in the Localization topic 's Create Dictionaries for Other Locales section. Note that XAF Mobile applications use the modular approach.