Properties prop = new Properties();
FileInputStream fis;
try {
fis = new FileInputStream( "xmlpath.properties ");
prop.load(fis);
fis.close();
} catch (FileNotFoundException e) {
e.printStackTrace();
} catch (IOException e) {
e.printStackTrace();
}
String str = prop.getProperty( "th001 ");
[xmlpath.properties]文件,中这样的数据
[th001=./xlsFile/領収書.xls],后面的日文
str 返回的是[./xlsFile/??????.xls]
请知道的朋友,指点一下,谢谢了。
------解决方案--------------------
String str = prop.getProperty( "th001 ");改为
String str = new String(prop.getProperty( "th001 ").getBytes( "ISO-8859-1 "), "gbk ");