![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
From: Cedric (AT) discussions (DOT) microsoft.com Subject: VB.net 2005 Multi Language RESX Project Date: Thu, 4 May 2006 05:40:02 -0700 Newsgroups: microsoft.public.dotnet.internationalization Hello I'm currently working on a winform project that must be in 3 languages (French, English et Polish). I know that I have to work with *.resx files, (1 for each language, 1 for the default) but also 1 for each Form. The problem I have is that I must change the form and modify the objects on it (Textboxes, labels, comboboxes, etc) in the three language so as to have the object recorded into the corresponding resx file. It's a long job so I would like to know if there is a faster possibilty to include objects into the resx files. Moreover, How can I internationalize the messages shown in the messageboxes that I have in my forms still with the 3 languages. For example say "Bonjour" in French, "Hello" in English and "CześāE in Polish. Thanks for your answers |
#3
| |||
| |||
|
|
Hello Cedric. From the description of your problem, it sounds like you are editing controls on each language version of the forms. If you leverage WinForm's auto-layout features (Autosize properties, FlowLayoutPanel and TableLayoutPanel controls), you should only need to edit control properties on the default form. There's a good overview document available here: http://blogs.msdn.com/permanenttan/a...07/545445.aspx For message strings, you'll want to store them in the project's default Resources.resx file. Once all the strings are in this file, then you can make copies of this file for each language (in Windows Explorer), renaming each for the target language (e.g., Resources.fr.resx for French). You can then call the string via the default ResourceManager object like so: ' VB MessageBox.Show(My.Resources.msgHello) // C# MessageBox.Show(Properties.Resources.msgHello); Cheers, Garrett McGowan [MSFT Developer International] This posting is provided "AS IS" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at http://www.microsoft.com/info/cpyright.htm -------------------- From: Cedric (AT) discussions (DOT) microsoft.com Subject: VB.net 2005 Multi Language RESX Project Date: Thu, 4 May 2006 05:40:02 -0700 Newsgroups: microsoft.public.dotnet.internationalization Hello I'm currently working on a winform project that must be in 3 languages (French, English et Polish). I know that I have to work with *.resx files, (1 for each language, 1 for the default) but also 1 for each Form. The problem I have is that I must change the form and modify the objects on it (Textboxes, labels, comboboxes, etc) in the three language so as to have the object recorded into the corresponding resx file. It's a long job so I would like to know if there is a faster possibilty to include objects into the resx files. Moreover, How can I internationalize the messages shown in the messageboxes that I have in my forms still with the 3 languages. For example say "Bonjour" in French, "Hello" in English and "CzeÅ›ÄE in Polish. Thanks for your answers |
#4
| |||
| |||
|
|
From: AndrewEames (AT) discussions (DOT) microsoft.com Subject: RE: VB.net 2005 Multi Language RESX Project Date: Wed, 24 May 2006 04:24:02 -0700 Newsgroups: microsoft.public.dotnet.internationalization Don't copy the .resx file using Windows explorer - IMHO this is a big mistake since you copy all the resources you dont want to localize too. e.g. If you have a button location at x,y , copy the resources file to french and then move the button in English, the French location of the button doesn't change A better way to create the localized .resx files is to set the Localized property of the form to true, set the Form's language to the language you want and then create a dummy resource (to force VS to create the file) Andrew "Garrett McGowan[MSFT]" wrote: Hello Cedric. From the description of your problem, it sounds like you are editing controls on each language version of the forms. If you leverage WinForm's auto-layout features (Autosize properties, FlowLayoutPanel and TableLayoutPanel controls), you should only need to edit control properties on the default form. There's a good overview document available here: http://blogs.msdn.com/permanenttan/a...07/545445.aspx For message strings, you'll want to store them in the project's default Resources.resx file. Once all the strings are in this file, then you can make copies of this file for each language (in Windows Explorer), renaming each for the target language (e.g., Resources.fr.resx for French). You can then call the string via the default ResourceManager object like so: ' VB MessageBox.Show(My.Resources.msgHello) // C# MessageBox.Show(Properties.Resources.msgHello); Cheers, Garrett McGowan [MSFT Developer International] This posting is provided "AS IS" with no warranties, and confers no rights. Use of included script samples are subject to the terms specified at http://www.microsoft.com/info/cpyright.htm -------------------- From: Cedric (AT) discussions (DOT) microsoft.com Subject: VB.net 2005 Multi Language RESX Project Date: Thu, 4 May 2006 05:40:02 -0700 Newsgroups: microsoft.public.dotnet.internationalization Hello I'm currently working on a winform project that must be in 3 languages (French, English et Polish). I know that I have to work with *.resx files, (1 for each language, 1 for the default) but also 1 for each Form. The problem I have is that I must change the form and modify the objects on it (Textboxes, labels, comboboxes, etc) in the three language so as to have the object recorded into the corresponding resx file. It's a long job so I would like to know if there is a faster possibilty to include objects into the resx files. Moreover, How can I internationalize the messages shown in the messageboxes that I have in my forms still with the 3 languages. For example say "Bonjour" in French, "Hello" in English and "CzeÁE EE in Polish. Thanks for your answers |
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |