eclipse build problem

2019-07-13 02:59发布

问题:

when I try to build my Eclipse project, I get the following error message:

The type org.eclipse.swt.widgets.Composite cannot be resolved. It is indirectly referenced from required .class files

Can anybody help me to solve this problem? The Java-Build-Path contains the Plug-in-Dependencies-Library and org.eclipse.swt... is listed there.

I didn't have the problem last week (though nothing should have changed in the meantime). But it's not the first time that I get this typ of error...

回答1:

Finally, I could solve the problem with creating a new workspace and importing my project.



回答2:

I sometimes encounter this kind of stranges error and the only solutions I found to solve it are the following ones (no specific order and sometimes one is enough sometimes not):

  1. Select the project and clean ONLY this project, then rebuild
  2. Clean all the workspace
  3. Restart the workbench
  4. Disable "automatic build", clean all, the build only your project
  5. Remove the project from the workspace WITHOUT removing it from Hard drive and then import it again

I think this is a PDE issue.

Hope this can help, Manu