Sunday, April 29, 2012

Uninstall apk programmatically


First, make sure the emulator is running. Then follow below steps:

1. Go to the tools directory in command prompt – 
c:\>android\tools
2. Type 
adb shell
3. #
cd /data/app (this takes you to the folder where all apk files are installed)
4. 
#ls (It will display all the .apk installed in your emulator)
5. #
rm ***.apk (which you want to remove, all apk files)
6.#
exit (exits from the adb shell)

NOTE: to start the emulator, you can start it from eclipse by right clicking an android project and “run as” an “application” or by going to tools directory at command prompt and typing “emulator –avd <avd_name>”

No comments:

Post a Comment