0

Hi I've been getting a weird error when I try to use eclipse to generate getters and setters. I left clicked, then clicked on source then on generate getters and setters. I, however get an error that says:

The resource is not on the build path of a Java project

It's weird as it seems to be working for my other projects. Any ideas on how to fix this?

Thanks

mleko
  • 11,650
  • 6
  • 50
  • 71
Chris
  • 1
  • possible dublicate https://stackoverflow.com/questions/9464998/eclipse-the-resource-is-not-on-the-build-path-of-a-java-project – Mustafa Çil Jul 04 '17 at 08:45
  • Maybe you open the Java file from the wrong location. Have a look at this answer https://stackoverflow.com/questions/37803889/the-compilation-unit-is-not-on-the-build-path-of-a-java-project-maven/37804998#37804998 and check if the file is displayed with a solid or framed `J` icon. – SubOptimal Jul 04 '17 at 08:49
  • does this duplicated linked question has really something to with the setter getters here??? – ΦXocę 웃 Пepeúpa ツ Jul 04 '17 at 08:52

0 Answers0