Search code examples
androideclipseimportarchive

Problem importing Android project archives into Eclipse


My apologies if this is a stupid newbie question...

I'm using Eclipse (Helios release) and have the Android SDK all configured as per the developer.android.com recommendations. I can create and run new projects without any problem but I can't import archived project code samples (found on the web etc.) using Import > Existing Projects Into Workspace.

Importing a zip creates a project but it doesn't create it as an Android project and the console displays the error: "Project has no default.properties file! Edit the project properties to set one."

I've tried going into the project Properties but as soon as I click on 'Android' in the properties tree a pop-up appears saying "Could Not Accept Changes: The currently displayed page contains invalid values"

See: http://screencast.com/t/ZmY3ZWQ4

But if I do this on one of my own projects I have no such error, and I'm able to change things such as the Android Platform/API level. I'm also able to archive my own projects (using export) and import them again without any problems... nut not other people's archives! Am I being really stupid?

Any help would be really appreciated!


Solution

  • All the baseline default.properties needs is a line like:

    target=android-8

    You can most likely copy another projects' default.properties into this project. A (not-so-)quick restart of Eclipse, a rebuilding of the workspace, and you're off to the races.

    It's really lame that this is needed -- it should happen as part of the import process, I would think.