Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android application updates

We have developed an Android application and plan to install them on tablets and distribute to our clients. We now have to decide on a process to send updates to the application whenever they are available.

Can some one suggest the best approach to achieve this process of sending the updates?

Is a silent update possible i.e. updating application without user intervention by checking,downloading and installing the latest version from with in the application?

Thanks in advance, Navin

like image 879
NavinC Avatar asked Mar 09 '11 21:03

NavinC


2 Answers

You can use Google's C2DM service to send a push notification to the device telling it to upgrade. You can then have a broadcast receiver get the push notification and start the download. Check here for more details. http://code.google.com/android/c2dm/index.html

like image 76
Brian Griffey Avatar answered Oct 11 '22 19:10

Brian Griffey


The simplest solution I know of involves retrieving the current version number from the web, comparing it to the existing installed version and if there is an update available pop-up a dialog with a link to the Android Market page for the specific application.

So basically you decide when you want to check (application start, regular intervals, etc)

And then you query a remote file that contains the latest version number.

You compare this to the installed version number and if latest > installed show the user a link to the Android Market.

afaik you cannot do a silent update of the application, for security reasons

Here is some code where someone has implemented the above solution: http://www.androidsnippets.com/check-for-updates-once-a-day

Launching the android market on the device: http://developer.android.com/guide/publishing/publishing.html#marketintent

like image 45
Steven James Avatar answered Oct 11 '22 18:10

Steven James