如图所示:首次在properties里打中文注释,结果一输入中文就自动被转码,于是查看了一下项目的编码是UTF-8的,而eclipse中默认的properties文件编码是ISO的,所以修改一下即可。

myeclipse的properties文件中文被转码解决方案

打开window下的preferences,搜索框输入Content Types ,找到如下图的java Properties File修改默认编码

myeclipse的properties文件中文被转码解决方案

myeclipse的properties文件中文被转码解决方案

修改后即可成功:

myeclipse的properties文件中文被转码解决方案

相关文章:

  • 2021-08-30
  • 2021-07-17
  • 2022-12-23
  • 2021-11-27
  • 2021-05-20
  • 2022-01-19
  • 2022-01-03
猜你喜欢
  • 2021-04-07
  • 2021-08-09
  • 2021-08-13
  • 2022-02-09
  • 2021-10-12
  • 2021-12-02
  • 2021-10-25
相关资源
相似解决方案