扫描阿拉伯语字符netbeans 8 [英] scan in arabic characters netbeans 8
问题描述
我有这个简单的代码打印阿拉伯语句子和扫描阿拉伯语字符。
什么是driveme疯狂的是它打印在cmd右,但从来不扫描字符扫描阿拉伯文字符
的形式我试过一切: Scanner(System.in,UTF-8)
, UTF8);
请帮助
public static void main(String [] args){
Scanner in2 = new Scanner(System.in,UTF-8);
System.out.printf(ادخلجملةالسؤال\\\
);
String s = in2.nextLine();
System.out.printf(+ s +);
// TODO代码应用程序逻辑
}扫描器in2 = new Scanner(System.in,UTF-8);
System.out.printf(ادخلجملةالسؤال\\\
);
String s = in2.nextLine();
System.out.printf(+ s +);
输出:
BUILD SUCCESSFUL(总时间:11秒)
blockblog =>
解决方案我有同样的问题netbeans 8和窗口7
修复这个
打开
C:\Program Files\NetBeans 8.0 \etc\\\
etbeans.conf
您会发现这
netbeans_default_options =...
netbeans_default_options = - J-Dfile.encoding = UTF-8 -J-client ...
并重新启动Netbeans
检查此屏幕截图
I have this simple code that prints Arabic sentence and scan arabic characters .
what is drivingme crazy is that it prints in cmd right , but never scan characters it scans arabic characters in form of
��� �����
I tried everything:
Scanner(System.in,"UTF-8")
,Scanner(System.in,"UTF8");
please help
public static void main(String[] args) { Scanner in2 = new Scanner(System.in,"UTF-8"); System.out.printf(" ادخل جملة السؤال \n"); String s = in2.nextLine(); System.out.printf(""+s+""); // TODO code application logic here } Scanner in2 = new Scanner(System.in,"UTF-8"); System.out.printf(" ادخل جملة السؤال \n"); String s = in2.nextLine(); System.out.printf(""+s+"");
output :
ادخل جملة السؤال هذا تلميذ ��� �����
BUILD SUCCESSFUL (total time: 11 seconds)
解决方案i have the same problem with netbeans 8 and windows 7
to fix this please do that
openC:\Program Files\NetBeans 8.0\etc\netbeans.conf
you will find this
netbeans_default_options="..."
add this code at the begining of it so at the end it will look like that
netbeans_default_options="-J-Dfile.encoding=UTF-8 -J-client ..."
and restart the netbeans
check this screen shot
这篇关于扫描阿拉伯语字符netbeans 8的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!