No automatic compilation under Eclipse, or no files in the Web-inf/classes directory, the solution to the failed compilation (reproduced)

Source: Internet
Author: User

Article Source: http://www.cnblogs.com/xfiver/archive/2010/07/07/1772764.html

1. IOException parsing XML document from ServletContext resource [/web-inf/classes/beans.xml]; nested exception is JA Va.io.FileNotFoundException:Could not open ServletContext resource [/web-inf/classes/beans.xml]1. Make sure the project->build automatically has been selected.

2. If selected, does not work, use this trick: Project->clean. Select 2nd Clean Select Project, tick the start build immediatelly

3. Delete the current project, set the output path of the compiled file in advance, re-import the source file, set Eclipse to compile on save, and then compile it automatically when you save it.

4. If the project led to an unused jar package, and the package is deleted by you, it will appear without error, but how to compile the case of the class file, you can delete all the packages, and then one by one to introduce (need), do not bring all the package all at once, useless may cause undesirable consequences.


5. Want to delete a class file regeneration, after deleting the class file, but the folder under the Classes directory is opened by other programs, such as Total Commander. At this point the compilation will not pass, under problems may prompt "Con ' t delete classes ...". Turn off other programs to recompile.

6. There is also a situation where the JRE System Library is removed and re-imported to compile. The reason is that it is possible that when a team is working together, someone will submit a. class file, and when you update it, it causes your JDK file path to go wrong, causing the project to die without the JDK, which is to be re-imported.

7. Remove all packages from the build path. Then add Jars,add libraries the need to add in, incredibly began to compile ...

8.project->properties->java Build PATH->SOURCE->.../WEB-INF/SRC output folder do not default, edit let it point to: /web-inf/classes
Then click the Build project again to compile automatically.

Personal use this to solve the problem

9. Then the most important thing to see is whether the work directory is missing, because the CVS control does not add work as a version, so there is no directory after checkout, to manually add some projects can be automatically compiled

No automatic compilation under Eclipse, or no files in the Web-inf/classes directory, the solution to the failed compilation (reproduced)

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.