Have an amazing solution built in RAD Studio? Let us know. Looking for discounts? Visit our Special Offers page!
DelphiRAD Studio

Easily Deploy Advanced Android Kiosk Mode With This FireMonkey Template

advanced android kiosk mode template

With Embarcadero Delphi, this FireMonkey template demonstrates the new Android Kiosk Mode introduced in Android 6.0. Kiosk mode (lock mode) is a distinct application mode. These applications cannot be closed.

In this post, you’ll learn how to easily deploy advanced Android kiosk mode with the help and use of Android App Builder Software.

The purpose of this template is

  • Demonstration of launching applications in Kiosk Mode;
  • Make a simple, understandable mechanism for implementing the operation of the mode in any application.
firemonkey delphi kiosk mode application 7280092

 

All implementation of the mode is in the KioskApplication.pas module

  • StartLockTask (AOtherAppPackages: TArrayOfStrings = []) – starts Kiosk Mode. AOtherAppPackages – accepts an array of strings, package names of external applications that need access from your application. 
  • Example: StartLockTask ([‘com.android.settings’]);
  • StopLockTask – turns off Kiosk Mode;
  • CleanOwnerState – Clears the status of the application as the current owner of the device.

Create an instance of the TKioskApplication class and call StartLockTask after the application starts. It is also necessary to make a condition for exiting the application (for example, entering a password). Before closing the application, call StopLockTask.

You can get this FireMonkey template from GetIt Package Manager

getit package manager 7228896

Head over and find out more about the Android Kiosk template and then download it via GetIt in the IDE.

See What's New in 12.2 Athens See What's New in 12.2 Athens Dev Days of Summer 2-24

Reduce development time and get to market faster with RAD Studio, Delphi, or C++Builder.
Design. Code. Compile. Deploy.
Start Free Trial   Upgrade Today

   Free Delphi Community Edition   Free C++Builder Community Edition

About author

Software Developer | CS(CyberSec) Undergrad at APU Malaysia | Delphi/C++ Builder Enthusiast | Microsoft Learn Student Ambassador | Microsoft Azure Certified

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

IN THE ARTICLES