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 

Application always starts in invariant

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



Joined: 19 Jul 2011
Posts: 2

PostPosted: Tue Jul 19, 2011 6:53 pm    Post subject: Application always starts in invariant Reply with quote

I had assumed that when you started the application from the translator edition and selected a language, it would run the application in that language with your translation.

What I am finiding is that the application always starts in the OS language and ignores whatever language you select. Is there something I am missing?
Back to top
View user's profile Send private message
Infralution



Joined: 28 Feb 2005
Posts: 5027

PostPosted: Wed Jul 20, 2011 12:27 am    Post subject: Reply with quote

Globalizer changes your windows user account regional settings to the selected culture before starting the application (when Globalizer exits it reset the user culture to the original value). This means that if your application determines its default user interface culture based on the current user culture then it will start in the selected language. For this to happen your application must set the thread CurrentUICulture to the CurrentCulture before opening any windows/forms eg

Code:
Thread.CurrentThread.CurrentUICulture = Thread.CurrentThread.CurrentCulture;


If you don't do this then the UICulture will always be invariant. If you are writing a WPF App using Infralution's ResxExtension then instead you need to set the CultureManager.UICulture:

Code:
CultureManager.UICulture = Thread.CurrentThread.CurrentCulture;


The sample projects illustrate doing this.
_________________
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