Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Android app not in Market: how to push updates?

I have an android app written for my company and since its a private app, it is not in the android market. I'd like to be able to have the app check periodically for an update and if there is one notify the user and start downloading / installing the update.

Is there an example of something like this out there?

like image 738
Mike Avatar asked Aug 18 '10 19:08

Mike


People also ask

How can I update apps other than Play Store?

Download and install the APKMirror Installer app from the Google Play Store. You can download it from the Google Play Store, then use APKMirror Installer to install or update your apps afterward.

Can you force users to update app?

You can use https://appupgrade.dev/ service to force update you mobile apps. You need to create new version for your app versions you want to update in the app upgrade service and select whether you want to force it or just want to let users know that new version is available.


1 Answers

at the start of your app check the available version, the you can use an AlertDialog to ask for the upgrade.

Read this:: Is there a way to automatically update application on Android?

and this is an AlertDialog example::

    if (ConfigXML_app_version> myapp_version){
        AlertDialog.Builder builder = new AlertDialog.Builder(this);
        builder.setTitle("Upgrade");
        builder.setMessage("Update available, ready to upgrade?");
        builder.setIcon(R.drawable.icon);
        builder.setCancelable(false);
        builder.setPositiveButton("Yes", new DialogInterface.OnClickListener() {
            public void onClick(DialogInterface dialog, int id) {
                Intent intent = new Intent(Intent.ACTION_VIEW ,Uri.parse(app_link));
                startActivity(intent);               
                finish();
            }
        });
        builder.setNegativeButton("Nop", new DialogInterface.OnClickListener() {
            public void onClick(DialogInterface dialog, int id) {
                dialog.cancel();
            }
        });
        AlertDialog alert = builder.create();
        alert.show();

    }
like image 120
Jorgesys Avatar answered Oct 28 '22 14:10

Jorgesys