The 'Hello World' text should be replaced with 'Hello Uno', or 'Bonjour Uno' if the targeted environment is on French culture. Note: Be sure to hit Ctrl+S for both files, to save the changes. MainPage_CodeBehindString|String from code-behind|Texte provenant du code-behind MainPage_IntroText.Text|Hello Uno|Bonjour Uno Name|Value in en\Resources.resw|Value in fr\Resources.resw
Open both Strings\en\Resources.resw and Strings\fr\Resources.xaml, and add these: > Visual C# > Xaml > Resources FileĪdd the localization strings for both English and French: Add a new resource file Resources.resw under the fr folder by:.Add a new folder fr under the Strings folder by:.This.Loaded += (s, e) => CodeBehindText.Text = Ĭreate a new resource file for localization in French in the UnoLocalization.Shared project: In, add an Page.Loaded handler to change the text for CodeBehindText:.More on this in the resource steps that follow. To localize a property, you need to add a string resource in each resource file using its x:Uid followed by a dot (. The x:Name is used to make the element accessible from the code-behind with that same name.
Step-by-stepsĬreate a new Uno Platform application, following the instructions here. For a step-by-step guide to installing the prerequisites for your preferred IDE and environment, consult the Get Started guide.