MyEclipse of Chinese characters in Java class after importing a project in a program (resolved)

Source: Internet
Author: User

Today reinstall the system, after the installation of the new MyEclipse, after the import of the project, there has been garbled problem. The garbled question is mainly a comment in the Java class, but the Chinese characters in the JSP page are intact:

Right-click on the project, view the encoding format of the project, UTF-8, the Java file directly open with Notepad, no problem, no garbled, check the format of Notepad, GBK, it seems myeclipse cannot parse the reason for the Chinese character is because the Java file encoding format is not GBK, On the network, we found that the default encoding format for writing Java files in MyEclipse is GBK, so you can change the default encoding format of Java to GBK. The steps are as follows:

Windows--->Perfences-->

 

After the modification, the Chinese annotation in the Java file can be displayed normally.

MyEclipse of Chinese characters in Java class after importing a project in a program (resolved)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.