项目中间出现乱码解决方法:
android studio 导入xclipse项目出现乱码,及模拟器出现乱码解决方法

  1. 设置当前工程和IDE的编码 :AS窗口中点击File->Settings->Editor->File Encodings;将其中的Global Encoding设置为GBk; 以及将Default encoding for properties files设置为GBK; Project Encoding设置为GBK;(这里的JBK可以换成你需要的编码格式)
    android studio 导入xclipse项目出现乱码,及模拟器出现乱码解决方法
  2. 设置当前文件的编码: 找到软件右下角状态栏红色框起的,也修改为对应需要的编码格式,在这里我需要的是GBK。这样两边同时设置后才能解决乱码问题。
    android studio 导入xclipse项目出现乱码,及模拟器出现乱码解决方法

模拟器中出现乱码解决方法:

  1. 将项目设置为Android
  2. 打开bulid.gradle(Module:app),看清楚不要打开错了
  3. 在android里添加 compileOptions.encoding = “GBK”;后同步一下
  4. 问题解决 。
    android studio 导入xclipse项目出现乱码,及模拟器出现乱码解决方法

相关文章: