My application is already installed in the devise and i will get notification that you want to update, at one click i want my application get updated programmatically. Is there anyway to do...
Asked
Active
Viewed 2,846 times
0
-
I think there are way you have to uninstall app then install again. – Newts Dec 09 '11 at 12:44
-
That is the job of market app. Why are you circumventing it? – Aditya Kumar Pandey Dec 09 '11 at 12:44
-
Thanks for your responses, @Newts, can you suggest some ways to do that without user help – VKJ Dec 09 '11 at 13:20
-
@AdityaKumarPandey, my app will not be in market, just i will give notification to user to update. After clicking OK button it has to get updated. – VKJ Dec 09 '11 at 13:22
2 Answers
0
Third party developers are not able to install .apk files directly without user intervention.
But you can send request to PackageManager
to handle installation of new .apk file. This will show "install the app" dialog to user, and if she accepts the installation, your update will go through.
An example of the described scenario: Android: install .apk programmatically
0
The only way i'm seeing of doing that, and its NOT a good policy it to have the initial code swapping a specific directory for classes, and if it founds one, load it by reflection on the fly and "replacing" the classe contained in the APK
I don't think this will have a good performance... and should not i repeat NOT be a policy for update.

neteinstein
- 17,529
- 11
- 93
- 123