Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people, just like you, are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
Solved

Languages in Windows

Posted on 2001-06-22
8
283 Views
Last Modified: 2010-04-02
I have application with resources in two languages. Under WinNT it works and the language of running application depends on regional settings. But under Win2000 it depends primary on OS language and not on regional settings. Why? How to do it?

for example:
A...first lang., B...second lang. in res.
OS        OS lang.  Regional set.   Lang. of running app.
WinNT     A         B               B
Win2000   A         B               A (!!!)
0
Comment
Question by:lonicekm
8 Comments
 
LVL 5

Expert Comment

by:robpitt
ID: 6217647
The language loading rules employed are indeed inconsistant and confusing.

That said it was my recollection that NT/2000 behaved in the same way and that it was

Win95/98 that were a bit odd.

Anyway a quick search of MSDN revealed the following which may of help:
http://support.microsoft.com/support/kb/articles/q169/4/83.asp
http://support.microsoft.com/support/kb/articles/q221/2/09.asp
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dnintl/html/s24b3_b.asp

Rob
0
 
LVL 1

Expert Comment

by:xutao
ID: 6218212
   I don't know what rule you use in your application to identify the lauguage for use.
    There are two international feature API for us to get the language identifier of the current user locale [GetUserDefaultLangID()] and the user default-locale identifier [GetUserDefaultLCID].
    Use them you can easily know which language to use, at least I did.
    Good luck.
0
 

Author Comment

by:lonicekm
ID: 6223489
I don't use any rule, it chooses the language automatically. Under WinNT it works as I want and I don't need any extra code. How can I ordain explicitly f.e. what language version of the same dialog use?
0
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.

 
LVL 5

Expert Comment

by:robpitt
ID: 6223997
Oh my god! - I just did a little test and it would seem that the first link I posted ( http://support.microsoft.com/support/kb/articles/q169/4/83.asp ) is a blantent lie.

On my 2000 system "English US" resources allways seem to get loaded in preference to an exact Primary Lang / Sub lang match.

For example, if I set my regional settings are French France then English US still gets loaded in preference to French France.

However if I use English *UK* resources everything works as expected i.e. a best match is loaded.

Crazy.

Rob

0
 
LVL 1

Accepted Solution

by:
johnedwards2 earned 0 total points
ID: 6224183
Yeah there's defintely something fishy about the language loading stuff. Every time I think I understand it, I discover a scenario where it doesn't work as a I expect.

Alas the MSDN help and KB articles are very poor in this area.

Anyway the only reliable method I currently trust is to load the resources manualy using FindResourceEx but this is a real pain.
0
 
LVL 11

Expert Comment

by:griessh
ID: 6820019
I think you forgot this question. I will ask Community Support to close it unless you finalize it within 7 days. Unless there is objection or further activity,  I will suggest to accept "johnedwards2" comment(s) as an answer.

If you think your question was not answered at all, you can post a request in Community support (please include this link) to refund your points.
The link to the Community Support area is: http://www.experts-exchange.com/jsp/qList.jsp?ta=commspt

PLEASE DO NOT ACCEPT THIS COMMENT AS AN ANSWER!
======
Werner

0
 

Expert Comment

by:ComTech
ID: 6837684
Question had been deleted when I came to award question.

ComTech
CS @ EE
0
 
LVL 6

Expert Comment

by:Mindphaser
ID: 6996976
Force accepted

** Mindphaser - Community Support Moderator **
0

Featured Post

Free Tool: IP Lookup

Get more info about an IP address or domain name, such as organization, abuse contacts and geolocation.

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
convert char array to number in c 5 86
Socket Programming (Unix) 8 140
Unresolved External Symbols 3 103
show out valin of json for debugging in visaul c++ 1 41
Written by John Humphreys C++ Threading and the POSIX Library This article will cover the basic information that you need to know in order to make use of the POSIX threading library available for C and C++ on UNIX and most Linux systems.   [s…
This article shows you how to optimize memory allocations in C++ using placement new. Applicable especially to usecases dealing with creation of large number of objects. A brief on problem: Lets take example problem for simplicity: - I have a G…
The goal of the tutorial is to teach the user how to use functions in C++. The video will cover how to define functions, how to call functions and how to create functions prototypes. Microsoft Visual C++ 2010 Express will be used as a text editor an…
The viewer will learn additional member functions of the vector class. Specifically, the capacity and swap member functions will be introduced.

839 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