Hi All,
I have a reactive web application built in OS P11 and could not find the Multilingual Locale folder in the data tab. How to implement multilingual UI in reactive web apps built in OS platform 11?
Thanks,
KJ
Hi Karthik,
There is no multilingual resources like traditional web apps (for now).
You can make your reactive web app multilingual in same way it currently can be done for OutSystems mobile apps using the following Forge component:
https://www.outsystems.com/forge/component-overview/1784/multilingual-mobile-component
Regards,
Daniel
Daniël Kuhlmann wrote:
Thanks Daniel, I followed the instructions https://www.outsystems.com/forums/discussion/21245/multilingual-mobile-component-documentation and tried to implement multilingual feature by setting the SetLocale, its picking up the styles (Left to Right & Right to Left) but not the translated text. I have two locales in my application 1) English en-us 2) Arabic ar-sa with the following resource file and is loaded using the client action - AddTranslationsFromResource in OnApplicationReady. I have a text widget placed in my webpage with attribute
data-trans=1
Resource json :
[ { "locale": "ar_sa", "isRightToLeft": true, "translations": { "1": "???? ????? ?????????? - ??????" } }, { "locale": "en_us", "isRightToLeft": false, "translations": { "1": "English text from database" } }]
I am trying to change the locale by using SetLocale action based on the selection made by user through a dropdown.
Hello,
How to translate labels, text and expressions using the multilingual component without assigning the values using the
SyntaxEditor Code Snippet
GetTranslation(key, defaultText)
I tried by inserting the translation data into an entity and load it on OnApplicationReady, but Im able to translate expression only when i set it from a client action using the function - GetTranslation(). Is there any other options available to translate the labels, expressions & text directly?
To get a translation on your UI you have to use GetTranslation().
To get your translations you can either use a resource or for example an entity. Both methods are described in section 1.5 Load Translations.
What part you have problems with?
Thanks Daniel, I have my translations data in a database table and used AddTranslations action provided by Multilingual component and loaded it in OnApplicationReady. My question here is ,
whether the application widgets (with attribute data-trans='key') automatically picks up the text from the translation data based on the key and on the locale set using the SetLocale?
Or do I need to use the function GetTranslation(key,defaultvalue) and assign it to the widgets manually before loading all the web screens?
As far as I know you have to use GetTranslation, there is currently no other way to handle translations.