Link to home
Start Free TrialLog in
Avatar of AVaulin
AVaulinFlag for Ukraine

asked on

MessageBoxEx function

There is Win32 API function "MessageBoxEx". The last it parameter specifies the language in which to display the text contained in the predefined push buttons. I tried to call function with different language ID. However all time text appear in system language. I use English Pan European Windows'95 version. So buttons text is always English. But I need change language to another. Of course, I wrote my own MessageBox function analog which do what I want. But I want to know what must I do to compel API function work correctly.
Avatar of mbhakta
mbhakta

Install a Win 95 version of say, Norwegian or Chinese windows and try your code on that install.
Avatar of AVaulin

ASKER

I tried to run my program in different system language Win95. And of course the result is: all buttons text are in new language. But I want that buttons text will be different with system (MessageBoxEx function must give me this possible).
What are the ID's of your button. If you want Ok , Cancel buttons to have the same text no matter what language you are using try changing their ID's from IDOK to ID_OK etc. This way the text on the buttons will not change.
Avatar of AVaulin

ASKER

How can I change buttons ID for say MessageBoxEx( ..., ..., ..., MB_YESNOCANCEL, ...) ?
I would suggest if you want to do something like that you better create your own messagebox. It is a mess to do it on Windows Message boxes. I surely can be done in several different way but it is not worth the effort.
Avatar of AVaulin

ASKER

I already wrote my own MessageBox (see question text). Nevertheless I want know about MessageBoxEx function. I can tell next story: I use English Windows'95 and Russian Microsoft Word. All Word MessageBox buttons text is Russian (instead say Explorer where text is English). Recently I install RoboHelp program (by Blue Sky Software). This program is Word macro collection. There are MessageBox calls in it. And what I see? All buttons text is Russian!!! I don't think that Blue Sky Software knows Russian language. So Word can do what I want. Why I can't?
ASKER CERTIFIED SOLUTION
Avatar of strobert
strobert

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial