Solved

Problem in Localization with VB 6.0 using Resource Files

Posted on 2004-03-25
5
134 Views
Last Modified: 2010-05-01
Hi,

I am doing localization of my UI in VB 6.0. I have done that using Resource File - Multiple String Tables. While I am running my project in my development environment, it picks up and display the UI strings based on the current system locale and works properly.

The problem is when I am making the executable of my project and running, it always takes strings from the first string table in the resource file. How can I solve this issue?? Any information regarding localization would be appreciated.

Thanks in advance.

Regards,
Neha

0
Comment
Question by:it_nehapatel
  • 3
5 Comments
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 10676402
I recommend not to use strings tables based on Windows settings.

What I recommend is to use a resource file with a single table in which you define ranges for each language you want to support into which only an offset will change. For example, if you want to support English and French, you would do something like this:

1 - Hi
2 - Goodbye

10001 - Salut
10002 - Aurevoir

1 is the same as 10001 and 2 is the same as 10002. All you need to know from the user is the prefered language to set your offset. If the user choose English, your offset is 0. If French is selected, then the offset is 10000. In all your call to the resource file, you need to say (offset + 1) instead of (1).
0
 

Author Comment

by:it_nehapatel
ID: 10676558
Hi,

Thanks for the prompt reply. This is one way to do the localization.

Here the application has to get the input from the user and work accordingly. But I want my application gets the current system locale automatically and works accordingly. User don't have to supply any inputs.

Is there any way to do this?

Thanks and Regards,
Neha
0
 
LVL 70

Expert Comment

by:Éric Moreau
ID: 10676664
The problem if you look into the locale is that there are many French(...). If the user doesn't exactly what have been used into create the resource file, the first table is used.
0
 
LVL 70

Accepted Solution

by:
Éric Moreau earned 125 total points
ID: 11255766
points to emoreau
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
VBA filters 2 64
Visual Studio 2005 text editor 10 44
Export Data to Different .csv Files 26 114
VB6 - Cannot type when doing an extract from MSHFlexgrid to Excel 6 18
There are many ways to remove duplicate entries in an SQL or Access database. Most make you temporarily insert an ID field, make a temp table and copy data back and forth, and/or are slow. Here is an easy way in VB6 using ADO to remove duplicate row…
This article describes some techniques which will make your VBA or Visual Basic Classic code easier to understand and maintain, whether by you, your replacement, or another Experts-Exchange expert.
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

840 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