I am trying to create a new project from existing source code. I keep getting the following error: "Invalid Project Description", project path "overlaps the location of another project" with the same name. The reason is that I created that project from the source code before, but then I deleted that project and deleted its whole directory, before adding the source code directory again. I tried everything like cleaning and restarting, but nothing worked. I looked in my workspace directory, but there are no traces for the old project. There are several questions around this problem such as this Attempting Android Notepad Tutorial - Exercise 1 - More problems, but none of the answers worked for me!


当前回答

这个问题也快把我逼疯了,但我知道原因是什么。问题是eclipse不够聪明,不能在自定义的工作空间文件夹中创建与项目同名的文件夹。

解决这个问题的方法是确保你所有的项目都在一个与你的项目名称匹配的文件夹中,否则它会直接将你所有的项目文件转储到这个目录中。您最终看到这个错误的原因是因为它认为您正在将一个项目放在另一个项目中(可能读取了项目配置文件)。

I noticed this is especially a problem when not using the default workspace path. The way I solve this problem is to just add the Project Name to the end of location. So let's say you are putting a project named "HelloWorld" into /Users/name/Documents/projects/android/, you would want to manually add "HelloWorld" to the end of it, like this: /Users/name/Documents/projects/android/HelloWorld. This would ensure that the project is put in it's own folder called "HelloWorld" and not inside some other project. Be sure that if there are any projects not within folders into a folder of the same name as the project to solve the errors.

其他回答

我使用以下步骤解决了这个问题:

1) File -> Import
2) Click General then select Existing Projects into Workspace
3) Click Next
4) Browse the directory of the project

单击Finish。

这对我很有效

复制项目到你的工作空间,从eclipse文件>新建>项目创建新的Android应用程序项目,瞧。

以我为例,当我打开Eclipse并将计算机设置为睡眠模式,然后醒来工作时,我出现了错误“无效的项目描述”。我需要做的唯一一件事就是关闭我的Eclipse并再次打开它。 我看到当打开Eclipse并让计算机进入睡眠或休眠时,会犯许多其他奇怪的错误!

这个问题也快把我逼疯了,但我知道原因是什么。问题是eclipse不够聪明,不能在自定义的工作空间文件夹中创建与项目同名的文件夹。

解决这个问题的方法是确保你所有的项目都在一个与你的项目名称匹配的文件夹中,否则它会直接将你所有的项目文件转储到这个目录中。您最终看到这个错误的原因是因为它认为您正在将一个项目放在另一个项目中(可能读取了项目配置文件)。

I noticed this is especially a problem when not using the default workspace path. The way I solve this problem is to just add the Project Name to the end of location. So let's say you are putting a project named "HelloWorld" into /Users/name/Documents/projects/android/, you would want to manually add "HelloWorld" to the end of it, like this: /Users/name/Documents/projects/android/HelloWorld. This would ensure that the project is put in it's own folder called "HelloWorld" and not inside some other project. Be sure that if there are any projects not within folders into a folder of the same name as the project to solve the errors.

解决这个问题最简单的方法就是将项目移动到另一个文件夹并导入。这是因为您已经在该文件夹中有了该项目(或具有相同名称的项目)。当您删除project时,eclipse仍然保留对它的引用