Hi Max,

Java's default locale follows the default UI Language on Windows. So your Windows has to have Chinese UI package installed and selected as the default UI language. I don't have Windows 10 at hand, but Windows used to be capable of downloading/installing UI language packs on certain flavor of their Windows variations.

Naoto

On 8/9/16 7:52 PM, Weijun Wang wrote:
Hi Kris

Yes, it works, with -Duser.language.

Unfortunately, I am looking for a way to change the default/initial
locale, and then using these system properties to change the effective
locale again. :-)

Precisely, there is a test using grep to match warning messages and on a
Chinese Windows it cannot find the hardcoded English text. Since I only
have Windows in English, I need to a way to mimic a Chinese Windows
first, and then see if adding -Duser.language=en -Duser.country=US to
the test will make it work again.

On a Mac it's much easier.

Thanks
Max

On 8/10/2016 9:33, Krystal Mok wrote:
Hi Max,

Does setting -Duser.country=CN work for you? (I don't remember what the
correct name for China should be, but setting that to US forces java to
print the help message in English)

- Kris

On Tue, Aug 9, 2016 at 6:25 PM, Weijun Wang <weijun.w...@oracle.com
<mailto:weijun.w...@oracle.com>> wrote:

    My Windows 10 is English, but I want the java command to show
    Chinese help screen temporarily.

    I've tried "set LANG", chcp, "control intl.cpl,, /f:" but none works.

    Thanks
    Max


Reply via email to