Import the Problems and Solutions of the myeclipse project.

Source: Internet
Author: User

Import the Problems and Solutions of the myeclipse project.

1. If @ Override is added to the myeclipse method, an error is returned.

The following error is reported in the @ Override method:

The method oncreate (Bundle) of type HelloWorld must override or implement a supertype method

Override refers to the description that the subclass inherits the methods in the parent class.

Override is already available in JDK 5, but there is a Bug that does not support the implementation of the interface. I think this is not Override, and JDK 6 fixes this Bug, you can add @ Override to both the method Override of the parent class and the implementation of the interface.

 

Modify the compiler version specified by myeclipse in the java compiler option to change the compiler method in myEclipse at least 1.6 or later: project-> Properties-> Java Compiler-> Configure Workspace Setting, which can be set on the pop-up page.

 

2. access restriction Problems

Select your project-right-click Properties-find java build path-find libraries on the right
The following shows the JRE System Libriry. Here is the jar package you need to run the environment in the current JVM.
There is an Access rules under the Jre System Library. Double-click it to open it. The default Access rule is used here. The above drop-down box is changed to accessible. Enter ** below.

3. Set file encoding in MyEclipse

A. windows-> Preferences ...... Open the "Preferences" dialog box, left navigation tree, navigate to general-> Workspace, right Text file encoding, select Other, change to UTF-8, text file encoding in its properties dialog box is the UTF-8. b. windows> Preferences ...... Open the "Preferences" dialog box, navigation tree on the left, navigate to general-> Content Types, Context Types tree on the right, open each subitem in Text, and enter "UTF-8 ", click update! Other files related to java application development, such as properties and XML, have been specified by the Eclipse default, respectively for the ISO8859-1, UTF-8, such as the development of the need to change the encoding format can be specified here. C. window --> preference --> MyEclipse --> Files and Editors, change "Encoding" for each subitem to "ISO 10645/Unicode (UTF-8)", click Apply! D. After the above three steps, the new java file is UTF-8 Encoding

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.