none
How to display Chinese Characters in a C# Application?

    Question

  • I want to display Chinese Characters on the controls (e.g., buttons, lables, etc.) in C# .Net, but always failed with garbaged characters displayed (I have adopted NJStar to input Chinese Characters).

    How can I configure the Visual Studio .Net environment to implement the display of Chinese Characters in my Application?

    Smile
    Thursday, June 23, 2005 10:15 AM

Answers

  • Moonriver

    (1) To enable IME, do the following:
    a. Goto Control Panel->Regional and Language Options
    b. Select Languages->Details->Add
    c. At dropdownlist, select the language required. Try the different Chinese methods listed - they all have different input methods. I think the Chinese Taiwan one might be the one used by most people typing Traditional Chinese.
    d. Select keyboard layout. Try different language/keyboard combination to get the right input method you require.
    e. Click OK. OK. OK to get back to desktop.
    f. You will see icon at bottom right of desktop which in my case says EN, ie. English. Click on it to select your language.  Only do this when you want to add in Chinese to your labels. Switch back to English when you re-start coding.
    g. Refer to the help icon for more info or see the following Microsoft link:

    http://www.microsoft.com/globaldev/handson/user/IME_Paper.mspx

    (2) I don't use NJStar and therefore I don't know the Unicode capabilities of it. But if you can get the above going, you don't need NJStar for typing in during c# development.

    Friday, June 24, 2005 10:39 PM

All replies

  • I understand c#.net supports Chinese characters by way of unicode.  I don't read/write Chinese myself but my app makes use of Chinese character contents.  I understand NJStar was written many years ago to support Big5 and gb Chinese encoding for the likes of Chinese Windows.  However, Windows 2000 onwards is fully unicode compliant and there is no longer a need for Chinese Windows.  If you want to make use of Chinese characters in Windows 2000 onwards, you just need to enable East Asian Font support via your Regional settings. Then use the Windows supplied Input Method Editor (IME) to type in your Chinese at the labels, etc. in your c# application. I just tried it and it worked!  You don't need NJStar -unless it has an IME for Unicode.

    As mentioned earlier, this is only applicable from Windows 2000 onwards. Win 98 doesn't support Chinese unless you have Win 98 Chinese Windows.  But if you do have Win 98 Chinese Windows, you may still not be able to use Chinese characters since Chinese Windows, as far as I know, uses either Big5 or gb and c# doesn't support these.

    Therefore, your problem could be because:
    - You are using Windows 98
    - You don't have East Asian Fonts enabled
    - Your NJStar setup isn't generating Unicode, ie. it is encodng Big5 or gb

    Hope the above helps.

    Thursday, June 23, 2005 1:43 PM
  • Mo,

    Thanks for the help.
    I have already activated the East Asian Language Support on my Win-XP PC. However, I still have two questions to seek for your help:
    (1)How can I install/start the IME application as you had mentioned?
    (2)How can I implement the Unicode mode from NJStar input.

    Moonriver
    Friday, June 24, 2005 3:58 PM
  • Moonriver

    (1) To enable IME, do the following:
    a. Goto Control Panel->Regional and Language Options
    b. Select Languages->Details->Add
    c. At dropdownlist, select the language required. Try the different Chinese methods listed - they all have different input methods. I think the Chinese Taiwan one might be the one used by most people typing Traditional Chinese.
    d. Select keyboard layout. Try different language/keyboard combination to get the right input method you require.
    e. Click OK. OK. OK to get back to desktop.
    f. You will see icon at bottom right of desktop which in my case says EN, ie. English. Click on it to select your language.  Only do this when you want to add in Chinese to your labels. Switch back to English when you re-start coding.
    g. Refer to the help icon for more info or see the following Microsoft link:

    http://www.microsoft.com/globaldev/handson/user/IME_Paper.mspx

    (2) I don't use NJStar and therefore I don't know the Unicode capabilities of it. But if you can get the above going, you don't need NJStar for typing in during c# development.

    Friday, June 24, 2005 10:39 PM
  • Moonriver

    (1) To enable IME, do the following:
    a. Goto Control Panel->Regional and Language Options
    b. Select Languages->Details->Add
    c. At dropdownlist, select the language required. Try the different Chinese methods listed - they all have different input methods. I think the Chinese Taiwan one might be the one used by most people typing Traditional Chinese.

    I come from Vietnam, and can not see Vietnamese in this list, how can i do??

    Tuesday, May 16, 2006 7:11 AM