Solved

Multilingual applications

Posted on 2014-04-15
3
593 Views
Last Modified: 2014-04-15
I would like to know is there a good means to achieve a multilingual application.  I am aware that most Microsoft controls allow for localisation.  Is there a facility similarly for error provides and message boxes etc.  For example using resource file/s?
0
Comment
Question by:Alyanto
3 Comments
 
LVL 40

Accepted Solution

by:
Jacques Bourgeois (James Burger) earned 250 total points
ID: 40001037
Yes, there is.

You first create entries for the default language in the Resources tab of the project's Properties window, by giving them a name, and then the text you want to display.

Make sure you close the window so that the changes are saved before you go on for translation.

In the Solution Explorer, activate the button to Show All Files, and open the My Project folder (Properties if you are in C#). Make a copy of the resources.resx file, and give it the same extension as the ones that were generated when you created the forms, like resources.fr.resx for French.

Right click on the file and make sure to include it in your project. Then DoubleClick on it. You will find yourself in the resources editor. Keep the same names but translate the text.

You can use these resources in the code anywhere you could have a String, using the following syntax:

MessageBox.Show(My.Resources.YourResourceName) 'VB
MessageBox.Shoe(Properties.Resources.YourResourceName); //C#

Open in new window

0
 
LVL 79

Assisted Solution

by:David Johnson, CD, MVP
David Johnson, CD, MVP earned 250 total points
ID: 40001039
It all has to do with localization settings  .. A good example is here: Globalization and Localization in .NET - http://goo.gl/bFxijW
0
 
LVL 1

Author Closing Comment

by:Alyanto
ID: 40001178
Thank you gentlemen, I think I have enough here to construct my solution.  I liked James simpler method of creating resource files and David's recommended reading gave me a lot of ideas about how best to structure the information in each resource file.

/Aly
0

Featured Post

3 Use Cases for Connected Systems

Our Dev teams are like yours. They’re continually cranking out code for new features/bugs fixes, testing, deploying, testing some more, responding to production monitoring events and more. It’s complex. So, we thought you’d like to see what’s working for us.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This article is for Object-Oriented Programming (OOP) beginners. An Interface contains declarations of events, indexers, methods and/or properties. Any class which implements the Interface should provide the concrete implementation for each Inter…
This article aims to explain the working of CircularLogArchiver. This tool was designed to solve the buildup of log file in cases where systems do not support circular logging or where circular logging is not enabled
Established in 1997, Technology Architects has become one of the most reputable technology solutions companies in the country. TA have been providing businesses with cost effective state-of-the-art solutions and unparalleled service that is designed…
Nobody understands Phishing better than an anti-spam company. That’s why we are providing Phishing Awareness Training to our customers. According to a report by Verizon, only 3% of targeted users report malicious emails to management. With compan…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question