Solved

Languages in Windows

Posted on 2001-06-22
8
279 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
Comment Utility
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
Comment Utility
   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
Comment Utility
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
 
LVL 5

Expert Comment

by:robpitt
Comment Utility
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
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 
LVL 1

Accepted Solution

by:
johnedwards2 earned 0 total points
Comment Utility
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
Comment Utility
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
Comment Utility
Question had been deleted when I came to award question.

ComTech
CS @ EE
0
 
LVL 6

Expert Comment

by:Mindphaser
Comment Utility
Force accepted

** Mindphaser - Community Support Moderator **
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Often, when implementing a feature, you won't know how certain events should be handled at the point where they occur and you'd rather defer to the user of your function or class. For example, a XML parser will extract a tag from the source code, wh…
Introduction This article is the first in a series of articles about the C/C++ Visual Studio Express debugger.  It provides a quick start guide in using the debugger. Part 2 focuses on additional topics in breakpoints.  Lastly, Part 3 focuses on th…
The goal of the video will be to teach the user the difference and consequence of passing data by value vs passing data by reference in C++. An example of passing data by value as well as an example of passing data by reference will be be given. Bot…
The viewer will learn how to user default arguments when defining functions. This method of defining functions will be contrasted with the non-default-argument of defining functions.

744 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

Need Help in Real-Time?

Connect with top rated Experts

12 Experts available now in Live!

Get 1:1 Help Now