android eclipse projects in package explorer disappears - android

Hi I am having problems with the Eclipse for android development.
After the computer is hanged I restarted again and open Eclipse the package Explorer shows nothing.
I tried to reboot computer / reboot Eclipse, but still fails
I then tried import back those app (say abc project) that beforehand developed but it says it duplicates the abc project that already exists. It appears that the package folder has actually something inside but the projects just appear invisible. How could that be repaired?
I have researched through the web but find no way out. It makes me headache...are there any method for repairing?
Thanks in advance for all your help!

You already have the project inside the workspace but eclipse is not recognizing it. In this case, You'll have to re-import the project.
Copy the code from the workspace through your windows explorer (or finder in mac) and paste it outside your workspace.
Then import it again using the code you just pasted outside. Check "Copy projects into workspace" option while importing.
Delete the code you copied outside the workspace.
The project will be re-imported and there will only be one copy inside your workspace.
Also see:
How to import existing Android project into Eclipse?

Try create another workspace and copy the projects there, then delete the older workspace and rename the created workspace. Should work.

Related

Import project with no .project file

I am trying to import a project in Eclipse (it's the Google Play services library, to use with Google Maps Android API v2, downloaded from the SDK Manager and located on my computer at <android-sdk-folder>/extras/google/google_play_services/libproject/google-play-services_lib).
It's not working and from what I've found, because of the absence of the .project file at the root of the project. Eclipse says "No projects are found to import".
Here is a screenshot.
Thanks for your help.
Create a new Android project from existing source instead of importing it.
Be Careful, Follow these steps and save your time
Right Click on your Project Explorer.
Select New-> Project -> Android Application Project from Existing Code
Browse upto this path only - "C:\Users**your path**\Local\Android\android-sdk\extras\google\google_play_services"
Be careful brose only upto - google_play_services and not upto google_play_services_lib
And this way you are able to import the google play service lib.
Let me know if you have any queries regarding the same.
Thanks
I got this error when I tried to import a general project instead of importing an android project.
my solution to this was
1.- Copy and paste google-play-services_lib to your Desktop
2.- Import using an existing project
Select New -> Existing Project in your Workspace I selected Desktop directory checked copy projects to your workspace and Finish
it worked
maybe if you use the original directory it is too large path and maybe eclipse cut it (I am suposing it)

How to open existing project in Eclipse

I kind of feel stupid, but I just can't get it to work....
I have an existing Android project copied from my other pc, in the folder
c:\projects\trunk\android\emergency
(I created that project on the other pc, copied it to my new pc and the other pc is given away)
Now I want to open the project in Eclipse. So I THINK I tried everything, but I can't seem to get it to work...
I looked for something like 'open project', but didn't find it.
Then I tried 'import', but that wouldn't let me import it because it was the same workspace (I use the same filelocations and workspace location as on the other pc)
Then i tried creating a new workspace and import it there. Then it complained about have no project, that i first had to create one. So i did create a dummy one in the new workspace, imported the project, and it copied everything to the new workspace, and placed it below the dummy project.
I am SO stuck, can you help me?
Btw, this is the Eclipse i'm using:
Eclipse SDK
Version: 4.2.0
Build id: I20120608-1400
Try File > New > Project... > Android Project From Existing Code.
Don't copy your project from pc into workspace, copy it elsewhere and let the eclipse copy it into workspace by menu commands above and checking copy in existing workspace.
It's the "Import existing project into workspace" option under Import->General.
See:
http://help.eclipse.org/helios/index.jsp?topic=%2Forg.eclipse.platform.doc.user%2Ftasks%2Ftasks-importproject.htm
Window->Show View->Navigator, should pop up the navigator panel on the left hand side, showing the projects list.
It's probably already open in the workspace, but you may have closed the navigator panel, so it looks like you don't have the project open.
Eclipse using ADT Build v22.0.0-675183 on Linux.
File > Import > General > Existing Projects into workspace.
Select the root folder that has your project(s). It lists all the projects available in the selected folder. Select the ones you would like to import and click Finish. This should work just fine.
i use Mac and i deleted ADT bundle source. faced the same error so i went to project > clean and adb ran normally.
Right click in navigator-Import-existing project..-select the base directory of your project
Assume that the application folder is in your pen drive.
open eclipse, go to import,select Android,In Android select "existing android code into workspace"
next and finish.
Ramanand Bhat

Eclipse Projects not loading in my Package explorer?

i was developing Android applications on my macbook pro after which i had to shift to the iMac at work. So i copied my Eclipse directory and the android sdk and the workspace and pasted it on the iMac at work.
I have set the Android sdk root inside the preferences of the Eclipse but the workspace is not loading inside my package explorer?
i have made the workspace folder inside the documents folder where it was in my macbook pro.
When Eclipse starts i choose the specified path of my workspace and then start eclipse.
Why are my workspace projects not being available in my package explorer?
thank you in advance.
EDIT:
i imported the project into my workspace. But there was .classpath 5.0 compatibility error, so i right clicked on my project and clicked android tools -> fix project properties. That error regarding .class path compatibility went away but a new error came in which the whole src folder inside my project has errors.. i mean each and every class.
And the error is regarding classes that come in the Android library...for eg. it is giving me error in the getCount method saying there is no such method in a class i used to extend the BaseAdapter class..what is going wrong here?
i have cleaned my project several times, but no change.
I just experienced something similar - had to create a new workspace and import the projects from my previous workspace to make it work. Pretty annoying, but it seems to be a bug in Eclipse.
Make sure that the build path of the project links correctly to the Android SDK. Right click on the project and choose configure build path and make sure that there are no red marks there.
Your project list is stored at .metadata.plugins\org.eclipse.core.resources\projects\, so you might want check that file to see if your projects are there.
from : Eclipse - No project visible in explorer
What helped me is i went to the package explorer and on the right site click the menu i.e. go to Filters -> Non Shared Projects. Remove that check mark. Then i see all projects.

Move Android Eclipse project into workspace

Eclipse is really bugging me with this. I have an Android project that is not in the workspace. Since Android projects don't work correctly if you use Eclipse's Import>existing project you have to make a new Android project from a folder on disk. If this folder
is in your workspace, it won't work. If it isn't it works, but then the project is located outside of my workspace folder, which is irritating. Does anyone know a way around this?
You can fix this by following this alternative import flow:
Make sure your project folder you want to import is in your workspace folder
In Eclipse, go to File → Import...
Click General → Existing Projects into Workspace
Make sure the "Select root directory" radio button is selected, and browse to your workspace directory.
In the Projects box, check the box next to the project folder you want to import and click Finish.
This will properly import your Android project.
I've experienced this problem too, when, for example, I tried to create a new android project based on existing source (the Notepad Exercise 1 example program that the android developer's documentation provides). I believe the problem you are experiencing with Import not working is that what you are trying to import a "project" that isn't really an Eclipse project at all (e.g. no .project/.classpath - it's just source code with a directory structure that deceptively looks like a project).
Like cisteams has alluded to above, if this is the problem, the procedure around this goes something like this:
Make a new android project choosing "Create project from existing source", making sure that the source directory is indeed outside your workspace (you'll have to live with this for a second). This should a) make the necessary .project/.classpath files in the source directory (which is still outside your workspace for now) and b) make the project show up in your list in Eclipse.
Right click the project in the Package Explorer and choose Delete, making sure that the option to delete files on disk is unchecked when it comes up.
Now import the project like you would any other project (you can do this now because the .project/.classpath files were created in step 1 above). There should be an option when importing for "Copy projects into workspace", so tick that option.
And you should be done. You can go back now and delete the copy of the project that isn't in your workspace to avoid confusion later on.
What version of Eclipse and ADT are you using?
Currently this approach is working fine for importing projects that are checked out from SVN. It does require that you have a .project and .classpath files (normally they are checked in to revision control).
If you do not have these files (some open source examples don't include them) then you need to use the Android Wizard for creating a new Android project from existing source. The key here is that it is a New not an Import, so yes it doesn't like it if the files are in the workspace. What you can do is create the new project externally using the wizard to create the .project and .classpath files. Once those exist you can use the normal import to bring the files into your workspace (and check those missing files into your source control).
Also you must delete the current install on your phone or you will get a signature fail from other comps install of the same app. So do the above and uninstall app off your phone before running the app on the new computer.

I did not understand the notepad sample in samples

Hi i did not understand the notepad sample in android.when i import this to my workspace it shows there are no projects.Its having sqlite code i want to see how this application running,Please explain it once
First of all your question is not clear...
Do you mean that after importing this project into eclipse you are unable to see it on your workspace located in ur PC ? If yes then you need to import them on your workspace.
By default while opening a project it remains in the respective physical location on the disk unless we explicitly mention that it needs to copy the project on to the workspace. On eclipse right click select Import-->General -->Existing projects on workspace-->select your project location and check copy projects into workspace. This would copy your project to the workspace.

Categories

Resources