I am using eclipse and i get this error--I think it's an error with the way i imported becker.robots

后端 未结 4 1952
刺人心
刺人心 2021-01-29 12:43

I am using eclipse and i get this error:

Exception in thread \"main\" java.lang.Error: Unresolved compilation problem:     at Wall.main(Wall.java:6)
4条回答
  •  悲&欢浪女
    2021-01-29 13:05

    Your problem is that becker.jar is just listed in your source folder (it is not source, it is a compiled jar and therefore should be in a lib folder, and then added to the Build Path). Eclipse can't find your import becker.robots.* because it doesn't know about becker.jar. Move becker.jar to /lib/becker.jar, and then Right Click on your Project Folder > Properties > Java Build Path > Libraries Tab > Add Jar > (select your lib/becker.jar). That should resolve your compilation error.

    A side note - the reason the error shows up as line 6 is because that is where the main method is (this is what actually is being run when you try to run the application), and when attempting to run the main method it identifies the build error that is really on line 1

提交回复
热议问题