Results 1 to 3 of 3

Thread: How can i have multiple languages within my application

  1. #1
    Haxaro is offline VB.NET Forum Fanatic
    .NET Framework
    .NET 4.0
    Join Date
    Mar 2009
    Posts
    105
    Reputation
    102

    How can i have multiple languages within my application

    I have an application that has gone quite big, and i have some friends in other countries that want translations for it... How could i include the information within the program so that if i want to run the program in english, i can, or in french / german etc.

    Would i have to create a setting for every button, textbox etc, so that the text in the control is the language is what they want, so if i want the application in french, i can click french and it changes the whole app into french etc. There could be up to 16 different languages...

    Easiest way?

  2. #2
    jmcilhinney's Avatar
    jmcilhinney is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.0
    Join Date
    Aug 2004
    Location
    Sydney, Australia
    Posts
    13,798
    Reputation
    1704
    You configure your controls to load their text from your resources. You then create a separate resource file for each culture. A culture is basically a country/language pair. The app will then automatically load the correct resources based on the current culture settings of system.

    For more information you should read about globalization and localization on MSDN. Globalization is the act of making your app support multiple cultures, i.e. read control text from resources. Localization is the act of making your app support a specific culture, i.e. adding a resource file for that culture.

    globalization localization - MSDN Search

  3. #3
    jmcilhinney's Avatar
    jmcilhinney is offline VB.NET Forum Moderator
    .NET Framework
    .NET 4.0
    Join Date
    Aug 2004
    Location
    Sydney, Australia
    Posts
    13,798
    Reputation
    1704
    Just note that something to consider is the dimensions of controls, e.g. the Text of a Button may be very short in one culture and very long in another.

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •