Search code examples
androidandroid-screen-pinningandroid-update-app

Android Screen Pinning - Update of App


Hi i've developed an android app which is screen pinned (using admin receiver). I've also put an automatic update check (my own server). When there is an update it downloads the APK and starts an intent to install it.

As the screen is Screen pinned it will not allow me to start or see the install screen so i can click the install button.

Is there anyway round this? The update method works when the screen is not pinned but that defeats the object of me screen pinning.

Thanks


Solution

  • I've found a work around which isn't ideal but will be fine for now.

    Using this post i was able to insert my code to take it out of screen pinning then start the install. Install dialog has two buttons Cancel or Install. On cancel button the app went back to screen pinning.

    After install the user has the option to click Done or Open. On done it went back to the Home screen. Fortunately my app is the home screen anyway and when my app loads it goes back to being pinned.