1
2 String b="";
3 String tmp=null;
4 try {
5 File f=new File("F:\\Eclipse\\MobileChart\\sms");
6 InputStreamReader isr= new InputStreamReader(new FileInputStream(f),"gb2312");
7 BufferedReader br=new BufferedReader(isr);
8 while((tmp=br.readLine())!=null)
9 {
10 b+=tmp;
11 }
12 }catch(Exception e){
13 e.printStackTrace();
14 }
如上面代码所示 只要指定 编码形式就行了