Android developer _ share a bug solution R. Java was modified manually! Reverting to generated version!

Source: Internet
Author: User

R. Java was modified manually! Reverting to generated version!


After entering eclipse, the menu --> project --> clean is equivalent to deleting the r file and then generating the r file automatically. If the r file is not automatically generated, there is an error in the program, which is generally a naming problem.

I encountered the following problems:

(1) control naming conflicts in different XML files in the layout folder.

Solution: the control name must be unique, that is, the control name of Chongming should be changed, and then the Clean Project will automatically generate the r file.

(2) The res folder can contain only corresponding folders, but cannot contain files or images.

(3) The file names in the res folder must be in lower case.

In short, the R file is automatically generated as long as the res file is correct.


Errors occurred during the build. errors running builder 'android pre compiler 'on project' project name' Java. lang. nullpointerexception. in this case, I upgraded the ADT and modified the ID in the layout XML. Do not repeat it!
There are also sayings on the Internet:

The reason is that SVN is used. As a result, SVN generates a file under all the files in the checkout folder. SVN files are used to manage version libraries. The new version of ADT enhances the identification of abnormal file types in project files. SVN returns a null pointer error.

Solve the problem: delete all the. SVN directories in the project and recompile them.

It is important to check the layout XML.

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.