eclipse导入项目提示已存在(Some projects cannot be imported because they already exist in the workspace)

时间:2023-01-17 15:31:20

在导入项目时,提示Some projects cannot be imported because they already exist in the workspace;但是我已经修改过.project文件里项目名称,但是还是不能导入,从网上搜到这片文章,原来是这样,需要在eclipse的工作空间找到相关记录,进行删除:工作空间并不存在同名项目,定是还有地方记录了之前的工程信息,可能是。。。找到:\xxxxxxxx\workspace\.metadata\.plugins\org.eclipse.core.resources\.projects 文件夹,删除同名文件夹

记录下解决此问题的方法:

MyEclipse无法导入Java项目时常遇到的两种情况:

1、Some projects cannot be imported because they already exist in the workspace

2、Some projects were hidden because they exist in the workspace directory
原因:workspace中已经存在了相同名字的项目,所以不能导入。
解决:
1、修改项目名:右击--- refactor --- rename 或 F2

2、打开项目中.project文件 --- 修改<name>projectName</name>

3、工作空间并不存在同名项目,定是还有地方记录了之前的工程信息,可能是。。。找到:\xxxxxxxx\workspace\.metadata\.plugins\org.eclipse.core.resources\.projects 文件夹,删除同名文件夹。



文章来自http://blog.csdn.net/leo_tung/article/details/48786373,谢谢作者哈。