46
Views
4
Comments
Solved
Setting default locale

Good morning!

I was developing an app both in Portuguese and English, however now I want it only to be in Portuguese.

The default language right now is English. 

Any idea on how to change it to Portuguese by default?

Thanks a lot!

2016-04-22 00-29-45
Nuno Reis
 
MVP
Solution

Of all the options, I'd go with the final link and João Marques advice:

In all your layouts create a OnInitialize and in all SetCurrentLocale for "pt-PT".

This way, all pages (as long as they use a Layout and they probably do) will have that logic.


Notice that you only need to set it on the first page called, so this system works for probably everything you can think of.

2026-02-26 06-29-24
Rahul
 
MVP

@Helga Afonso ,

You can use SetCurrentLocale action and set you locale.

Also use client variable or site property for set default local whenever the app running it load based on this variable,

2016-04-22 00-29-45
Nuno Reis
 
MVP
Solution

Of all the options, I'd go with the final link and João Marques advice:

In all your layouts create a OnInitialize and in all SetCurrentLocale for "pt-PT".

This way, all pages (as long as they use a Layout and they probably do) will have that logic.


Notice that you only need to set it on the first page called, so this system works for probably everything you can think of.

2025-01-21 06-16-34
Sant Das Dubey

First you need to select a block which is called at the beginning of each screen of your app. Then you need to go to oninitialize action of that selected block. Inside oninitialize action of the block, you need to use SetCurrentLocale action and pass the language you want (based on your business, you can use site-properties also to pass the current language). After doing all this you need to go to data tab of studio. There you will have a folder (at bottom side) which holds translations of each of the texts you have on your application. You need to pass translations of each of the texts/statements over there.

Community GuidelinesBe kind and respectful, give credit to the original source of content, and search for duplicates before posting.