I am trying to move a project from one computer to another and having issues. I have tried.
File > New > Project ... > Android Project from Existing code
and
File > Import > Android > Existing Android Code Into Workspace.
Both look like they get me to the same place. I browse to the project location check the option to copy in existing workspace. When a click finish nothing happens. The dialog stays open and the project is to imported or opened.
Ryan
Maybe there is already a project in your workspace with same name. Check your workspace and rename that project.
Simple export method I tend to follow:
Save everything
Close Eclipse (And wait to completely close)
Then goto workspace folder
Select the project you're working on
Either simply copy to new location or compress to zip
Then using new system, either file open project by folder or zip
To open compressed project or copied folder:
File ---> Import
General ---> Existing Projects into Workspace
Browse either root directory or archive file
Screenshots below:
I want to import this sample project from android so I can study the code however I am getting this error. Anyone know why?
No projects are found to import
Goto File -> Import -> Android -> Import existing project into workspace
Import the project in above method it will works .. baby
Yupe, you are importing the android code which is not having the AndrodiManifest.xml file. so instead of importing "existig project into the workspace" you need to import Android Code into the workspace.
Eclipse
File->New->Project->Android Project from Existing code->browse
Have a look at It:
Goto File > New > Project
Select the type of project, click Next
Uncheck Use default location
Click on Browse to navigate to your source folder, or type in the
path to your source
Click Finish
Eclipse is looking for eclipse projects, meaning its is searching for eclipse-specific files in the root directory, namely .project and .classpath. You either gave Eclipse the wrong directory (if you are importing a eclipse project) or you actually want to create a new project from existing source(new->project->android project from existing source).
Or Import -> Android -> Import existing project into workspace
I think you probably want the second one, because Eclipse projects usually have separate source & build directories. If your sources and .class files are in the same directory, you probably didn't have a eclipse project.
Edit:
1) File->Import->General->Existing Projects into Workspace.
2) Select root directory: /path/to/project
3) Projects->Select All
4) UNCHECK both "Copy projects into workspace" and "Add project to working sets"
5) Finish
Try this:
File -> import -> General -> Existing Project in Workplace - > Browse
The following error occurs when I click on the imported google-play-services_lib in the package explorer:
The project description file (.project) for 'google-play-services_lib' is missing.
This file contains important information about the project.
The project will not function properly until this file is restored.
I have deleted Google Play Services from the SDK and re-installed it, but the same error occurs.
Edit: The problem has been solved. The google-play-services_lib folder was missing a file called .project
select the project google-play-services_lib and delete it from eclipse, but don't select delete from hard disk
Select File > Import > Android > Existing Android Code Into Workspace and click Next.
Select Browse.... Enter /extras/google/google_play_services/libproject.
if it still not working clean project and restart eclipse
source of my answer is redo step two in here
Worked for me when I imported without "Copy files to workspace"
What i have done. I have just copied the content of the
extras\google\google_play_services\libproject\google-play-services_lib
to google_play_services\ folder.
Now clean and build lay_service_lib and reference again that library to your project. Clean and Build your project again and DONE..
My WorkSpace is working now with this help.
I'm a beginner at Android and there's an existing Android project I'd like to import into Eclipse.
From googling I found I should do this via File/Import/Existing project, which I did (there is a .project file in the root directory of the project I wish to open).
However after doing this Eclipse displayed an error message saying:
"ERROR: Unable to open class file C:\Users\ ..... \R.java: No such file or directory"
However the file R.java does exist at the location Eclipse is displaying in the error message.
Why does it think the file isn't there when it is?
How can I proceed to open the project?
TIA
I was able to import the project but after I cleaned the project I wasn't able to import the same project back to the same workspace. I think some files got deleted from the cleaning process.
I ended up changing the workspace directory and was able to get it working again.
Try to Clean your project and then Rebuild it. You could also try to manually delete the R.java file and Rebuild your project.
I'm trying to import and existing Android project into my current Eclipse workspace. I select File->New->Android Project, which brings up the Android project dialog, I then select, "Create project from existing source", Location, Build Target and Finish.
I get the following error: Invalid project description.
Does anybody know how to get past this error?
File → Import → General → Existing Projects into Workspace → Next
Select root directory: /path/to/project
Projects → Select All
Uncheck Copy projects into workspace and Add project to working sets
Finish
Solved: If you want to "Create project from existing source", you need to create a new directory and then put the project directory tree into that new directory. Then point to the new directory when importing.
This error message appears when the source code you try to import is inside an existing workspace.
Put your source code in a directory OUTSIDE any existing workspace and then import
Just delete the ".project" file in your project folder (it's hidden on Linux, use "ls -a" to show), then from Eclipse, choose Create Android Project from existing source
Im not sure this will solve your problem since I dont know where it originats from, but when I import a project i go File -> Import -> Existing projects into workspace. Maybe it will circumvent your problem.
It seems you cannot have your project root, with the AndroidManifest.xml deeper than one directory level below your workspace root. I struggled for an hour with this before I just gave up and rearranged my repo.
You can also use Make new > General > Project, then import the project to that project directory
I found James Wald's answer the closest to my solution, except instead of "File->Import->General->Existing Projects into Workspace" (which did not work for me at all) I used "File->Import->Android->Existing Android Code Into Workspace". I am using Helios, maybe your version of Eclipse does not have this quirk.
I had the problem of getting errors when checking out an Android project from SVN. This is what I did and the whole thing settled down.
1. checkout the project from SVN as we normally do any other project
2. right click and get properties of the project
3. In the java build path->order and export tab select the android API and OK it
this removed all the project issues
so far so good but not sure if this is the 100% correct method
This post helped me: http://code.google.com/p/android/issues/detail?id=8431
In my Android Project folder .project file was missing. Restoring the .project file,which will be hidden in Unix OS environment resolved the error.
Updating #JamesWald's answer, and incorporating other comments. Assuming you want to create a cfesh copy from, say, a backup in your new workspace:
Put the existing project in a directory not inside the destination workspace.
In Eclipse: File->Import->Android->Existing Android Code into Workspace, Next
Select root directory: /path/to/project/from/step/1
Projects->Select All (or not, as the case may be)
Make sure you set the new project name correctly - To change one click on the old project name (left column) and then click on the new project name (right column) and then edit. It will default to the class name of the Default Activity.
Assuming you want a copy in the destination workspace, check "Copy projects into workspace"
uncheck "Add project to working sets"
Finish
Same problem happened to me as well and the .project file was not there in the project.
I copied a .project file from an existing android project and replace the project name with the name of the project I am trying to import.
Then using File -> Import -> Existing projects into workspace I was able to import the project.
What works for me is that: File > Import > Existing Project into Workspace (under General tab), then choose the project root folder. The importing of Existing Android Code into Workspace somehow does not work on Eclipse for me.