diff --git a/AddedDefaultResourceFileInWPF.png b/AddedDefaultResourceFileInWPF.png new file mode 100644 index 0000000..a6a31e7 Binary files /dev/null and b/AddedDefaultResourceFileInWPF.png differ diff --git a/AddedGermanCultureResourceFileInUWP.png b/AddedGermanCultureResourceFileInUWP.png new file mode 100644 index 0000000..5df08f2 Binary files /dev/null and b/AddedGermanCultureResourceFileInUWP.png differ diff --git a/AddedGermanCultureResourceFileInWPF.png b/AddedGermanCultureResourceFileInWPF.png new file mode 100644 index 0000000..8ccffdc Binary files /dev/null and b/AddedGermanCultureResourceFileInWPF.png differ diff --git a/README.md b/README.md index e4f0d0a..6083e35 100644 --- a/README.md +++ b/README.md @@ -1,2 +1,55 @@ -# How to localize the drag and drop window text in treegrid? -This example illustrates how to localize the drag and drop window text in treegrid +# How to Localize the Drag and Drop Window Text in WPF / UWP TreeGrid? + +This example illustrates how to localize the drag and drop window text in [WPF TreeGrid](https://www.syncfusion.com/wpf-controls/treegrid) and [UWP TreeGrid](https://www.syncfusion.com/uwp-ui-controls/treegrid) (SfTreeGrid). + +To localize the TreeGrid, drag and drop window based on **CurrentUICulture** using resource files, follow the below steps. + +### For WPF: + +1. Create new folder and named as **Resources** in your application. + +2. Add the default resource file of TreeGrid into **Resources** folder. You can download the Syncfusion.SfGrid.WPF.resx [here](https://github.com/SyncfusionExamples/how-to-localize-the-drag-and-drop-window-text-in-treegrid/blob/ES-975464/WPF/SfTreeGridDemo/Resources/Syncfusion.SfGrid.WPF.resx). + +![Added the default resource file](AddedDefaultResourceFileInWPF.png) + +3. Right-click on the Resources folder, select **Add** and then **NewItem**. + +4. In Add New Item wizard, select the **Resource File** option and name the filename as **Syncfusion.SfGrid.WPF.<culture name>.resx**. For example, you have to give name as **Syncfusion.SfGrid.WPF.de.resx** for German culture. + +5. The culture name that indicates the name of language and country. + +![Adding resource file for german culture](ResourceFileForGermanCultureInWPF.png) + +6. Now, select Add option to add the resource file in **Resources** folder. + +![Added the german culture resource file](AddedGermanCultureResourceFileInWPF.png) + +7.Add the Name/Value pair in Resource Designer of **Syncfusion.SfGrid.WPF.de.resx** file and change its corresponding value to corresponding culture. + +![Added the name value pair in resource file](ResourceFileImage.png) + +![Localization applied to TreeGrid Drag and Drop](TreeGridWithLocalizationApplied.png) + +### For UWP: + +1. Right-click on the project, select **Add** and then **NewItem**. + +2. In Add New Item wizard, select the **Resource File** option and name the filename as **Syncfusion.SfGrid.UWP.Resources.<culture name>.resw**. + +![Adding resource file for german culture](ResourceFileForGermanCultureInUWP.png) + +3. For example, you have to give name as **Syncfusion.SfGrid.UWP.Resources.de.resw** for German culture. + +4. The culture name that indicates the name of language and country. + +5. Now the resource file is added. + +![Added the german culture resource file](AddedGermanCultureResourceFileInUWP.png) + +6. Add the Name/Value pair in Resource Designer of **Syncfusion.SfGrid.UWP.Resources.de.resw** file and change its corresponding value to corresponding culture. + +![Added the name value pair in resource file](ResourceFileImageUWP.png) + +You can get the TreeGrid's key from default resource [Syncfusion.SfGrid.UWP.Resources.resw](https://github.com/SyncfusionExamples/how-to-localize-the-drag-and-drop-window-text-in-treegrid/blob/ES-975464/UWP/Resources/Syncfusion.SfGrid.UWP.Resources.resw). + +![Localization applied to TreeGrid Drag and Drop](TreeGridWithLocalizationAppliedUWP.png) diff --git a/ResourceFileForGermanCultureInUWP.png b/ResourceFileForGermanCultureInUWP.png new file mode 100644 index 0000000..2189d12 Binary files /dev/null and b/ResourceFileForGermanCultureInUWP.png differ diff --git a/ResourceFileForGermanCultureInWPF.png b/ResourceFileForGermanCultureInWPF.png new file mode 100644 index 0000000..1b8b8fd Binary files /dev/null and b/ResourceFileForGermanCultureInWPF.png differ diff --git a/ResourceFileImage.png b/ResourceFileImage.png new file mode 100644 index 0000000..c1de984 Binary files /dev/null and b/ResourceFileImage.png differ diff --git a/ResourceFileImageUWP.png b/ResourceFileImageUWP.png new file mode 100644 index 0000000..2c289b3 Binary files /dev/null and b/ResourceFileImageUWP.png differ diff --git a/TreeGridWithLocalizationApplied.png b/TreeGridWithLocalizationApplied.png new file mode 100644 index 0000000..ab135ed Binary files /dev/null and b/TreeGridWithLocalizationApplied.png differ diff --git a/TreeGridWithLocalizationAppliedUWP.png b/TreeGridWithLocalizationAppliedUWP.png new file mode 100644 index 0000000..285e178 Binary files /dev/null and b/TreeGridWithLocalizationAppliedUWP.png differ