右键工程名->properties->java build path->libraries->Add library->jre system library->选择Alternate jre->导入你现在机器中的jdk(JDK开头的,而不是myeclipse自带的sun开头的)。确定之后就OK了。