Error: Could not find or load main class test.EditFile

  今天写了一个简单的小程序,运行之后发现Error: Could not find or load main class test.EditFile,项目无法启动。删除main中的所有内容之后依旧提示该错误。

 1 package test;
 2 
 3 public class EditFile {
 4 
 5     /**
 6      * @param args
 7      */
 8     public static void main(String[] args) {
 9         // TODO Auto-generated method stub
10 
11     }
12 
13 }

  查看problem,发现内容如下:The container 'JRE System Library [java-7-openjdk-i386]' references non existing library '/usr/lib/jvm/java-7-openjdk-i386/jre/lib/ext/pulse-java.jar'

  eclipse中,右击项目-properties-Java Build Path,发现JRE System Library上有红叉,选中remove,之后Add Library-JRE System Library-Installed JREs,发现原来配置好的jre不知道为什么突然都不见了,此时重新配置好,就OK啦

  问题解决

posted @ 2014-10-29 14:20  minxinfeng  阅读(1230)  评论(0编辑  收藏  举报