Infralution Support Forum Index Infralution Support
Support groups for Infralution products
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Only change UICulture, do not change Culture

 
Post new topic   Reply to topic    Infralution Support Forum Index -> Globalizer Support
View previous topic :: View next topic  
Author Message
peter



Joined: 16 Apr 2015
Posts: 1

PostPosted: Thu Apr 16, 2015 6:22 pm    Post subject: Only change UICulture, do not change Culture Reply with quote

We would like to only switch the UICulture, so that number formatting (Culture) stays at "en-US", which is set at the startup.

So, in other words, when a user starts our app from a german windows, numbers should be in "en-US" (that's working), and then when a user switches to french language, the texts should change to french (that's working) and the numbers should stay in "en-US" (not working).

Is that possible? This is our changeLanguageCommand:

private void ChangeLanguage(object language)
{
var lang = language as string;
if (lang == null) return;
CultureManager.UICulture = new CultureInfo(lang);
CultureManager.SynchronizeThreadCulture = true;
}

Best regards from Paris, Peter
Back to top
View user's profile Send private message
Infralution



Joined: 28 Feb 2005
Posts: 5027

PostPosted: Fri Apr 17, 2015 12:14 am    Post subject: Reply with quote

If you don't want the Thread culture (which controls formatting, dates etc) to be changed when you change the UICulture then you should set SynchronizeThreadCulture to false (before you change the UICulture).
_________________
Infralution Support
Back to top
View user's profile Send private message Visit poster's website
Display posts from previous:   
Post new topic   Reply to topic    Infralution Support Forum Index -> Globalizer Support All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group