Package explorer view in Eclipse
I am working on a project in Eclipse. Usually, whenever there are compilation errors in a particular file, the file name in the Package E开发者_如何转开发xplorer view is shown with a red box and a cross. This helps to find files with compilation errors easily.However, in one particular project, I have some files with compilation problems, but those are not shown with red in the package explorer. Only when I open the files in eclipse, do I see the compilation errors. Also, this behavior is happening only in one project. Other projects are showing compilation errors properly in the package view. Any idea why this is happening ?
Is there an error red cross on the project? Check the Problems view. (Window -> Show View -> Problems)
It could be that there is a build path error, or another error at the project level.
Often I've found that "cleaning" the project helps show those errors in the package explorer. Go to Project -> Clean... and select the projects you want to recompile.
Also it might even be easier to use the error view to jump directly to the source of your error without the lengthy way using the package explorer.
精彩评论