LabWindows/CVI

cancel
Showing results for 
Search instead for 
Did you mean: 

Anyone familiar with getResource() ? Multi-lingual programs ?

I need to make a program multi-lingual (change all texts from language A to B or C and back using a button or bar item) and I heard that getResource - function is a good way to do this. Can anybody tell me how to use this in a Labwindows/CVI program ? An example would be highly appreciated !
0 Kudos
Message 1 of 3
(3,137 Views)
See the answer of Chris Matthews in the following discussion thread: Link

Hope this help

Met vriendelijke groet / Kind regards,

Karsten
Applications Engineer
National Instruments
0 Kudos
Message 2 of 3
(3,137 Views)
Yes, very interesting literature, thank you !

Comment:
This does change the language of the ui. But the (error) messages in the example (hardcoded) are still all in English.

I have found a solution for the hardcoded texts though. I created in Visual C++ a DLL using 'Resource' only. For every language I want to use, this DLL must contain a separate STRINGTABLE. The resulting DLL (and a lib and an h.-file) I add to my project. Using the functions LoadLibrary, GetThreadLocale, SetThreadLocale and LoadString (all Windows SDK) I can let the user switch between languages using the language variables (LANG_ENGLISH, LANG_GERMAN, LANG_DUTCH etc).

It seems that GetLocaleInfo (as used int he example) uses a different windows variable than SetThreadLocale and GetT
hreadLocal, but this is no problem to my application.

Thanks you Karsten !
0 Kudos
Message 3 of 3
(3,137 Views)