Android development

I had a quick look at the Android SDK the other day and immediately hit what appears to be a common problem.

ActivityManager: Error: Activity class blah does not exist.

All I did was create a new Android project and run it without any customisation code at all.  I then spent an evening searching for a solution but nothing appeared to work. I tried re-creating the project but since I hadn’t modified the project in any way this was unlikely, I tried killing the debug process “{SDK_Location}/tools/adb kill-server”, deleting the userdata.img file. No change. I finally found a post suggesting to login to the adb shell and remove the deployed applications manually.

So I ran “./adb shell” in the SDK Tools folder and then cd’ed into the /data/app folder. I found in there all the old projects that I had created and run, i.e. several apk files. I deleted each one leaving the ApiDemos.apk which comes with Android. When I ran my project from Eclipse again, it started working 🙂

I am assuming the issue was caused as I had created a previous project for trying stuff out and subsequently deleted it and somehow adb got confused along the way.

It’s all fine now though so all I have to do is think of a killer app 😉 Anybody want a mobile TV Guide? Maybe I could sms back to MythTV to record shows???? That positioning LocationManager looks cool as well, but how’s it going to work on a security level? Will a user opt to have their location tracked?

I think Android is going to be big next year.

6 Responses to “Android development”

  1. Thanks, this is GREAT. I deleted all the .apk files I developed except for the demos and now my new app is running!

    Thank you very much for this post.

  2. thanks a lot, it is really helpful.

  3. Glad to have been of help 🙂

  4. Does not work for me

  5. It’s been a while and several new releases of the Android SDK. If it isn’t working any more then they’ve likely changed something that causes that. I haven’t had a chance to keep up with the new SDKs so can’t help right now. Sorry.

  6. Re-installation of aapt worked for me 🙂

Leave a Reply

Comment spam protected by SpamBam

© Copyright 2007 - BoraDev Consulting