Hi, I am trying to display menu items using japanese characters.

I am working on a Windows XP machine with English (US) as the default language. I also have the Japanese language pack installed.

I have placed the following in the .rc file

JAPTOOLBAR_MENU MENU
{
POPUP "?t?@?C??(&F)"
{
MENUITEM "????(&P)", MENU_PRINT
MENUITEM SEPARATOR
MENUITEM "?????(&Q)", MENU_QUIT
}
}

After compilation and running my program, the menu items is being shown as the same double-byte characters used in the .rc file.

Can anyone tell me how I can get the menu items to be displayed in Japanese?

Do I need to add anything to the code or change the settings on my machine?
Posted on 2004-12-30 02:49:08 by mockers
Try using the following line:
#pragma code_page(65001)
Posted on 2004-12-30 08:45:44 by Sephiroth3
Thx Sephiroth. that didn't seem to do the trick either.
Posted on 2005-01-09 21:20:45 by mockers
hmm i came across this piece of code



120 MENU
LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED
{
POPUP "&File"
{
MENUITEM "?????", 57601
MENUITEM SEPARATOR
MENUITEM "E&xit", 57665
}


how do i use

LANGUAGE LANG_CHINESE, SUBLANG_CHINESE_SIMPLIFIED


I know i need to define the constants value in the rc file

	

#define LANG_CHINESE 0x04
#define SUBLANG_CHINESE_SIMPLIFIED 0x0804


however i still can't get it to display the menu item in simplified chinese in this case.

Anyone have any clue or idea how to do this? thanks :-D
Posted on 2005-01-13 04:12:41 by mockers
Use Unicode perhaps?

I have no idea how to make DBCS work, or even if the resource compiler or menu system can handle it.
Posted on 2005-01-13 16:17:13 by tenkey
thanks all for your help.

managed to solve the problem.  :)

FYI: Unicode is the key.

Instead of using DBCS, I used the unicode characters and save the .rc file as Unicode text files.

This solution works on Windows XP, Windows NT doesn't seems to like it but thats ok.




Posted on 2005-03-23 01:24:07 by mockers