Android Question B4A Kiosk Mode (2017)

Magma

Expert
Licensed User
Longtime User
Hi there..

following the tutorial and help from Erel - read here:
https://www.b4x.com/android/forum/threads/device-owner-tasklock-kiosk-apps-2017.81765/

at step 2:

2. Connect the device to the PC in USB debug mode. Open command line and run the following command:
Replace your.package.name.here with the correct package name.

adb shell dpm set-device-owner mvt.client/anywheresoftware.b4a.objects.AdminReceiver2
mvt.client is the name of my package...

but getting the following message:

/system/bin/sh: dpm: not found

why ?
 

nobbi59

Active Member
Licensed User
Longtime User
Are you using atleast lollipop? As far as I know, dpm is only available since lollipop.
 
Upvote 0

Magma

Expert
Licensed User
Longtime User
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
Upvote 0

DonManfred

Expert
Licensed User
Longtime User
can i use the old way for kiosk mode - what's the difference ?
I dont know. I never need a KIOSK app.
As far as i know in the old Kiosk solution the user was able to go into the settings.
I dont know anything about a difference.
...Is it better (possible) to use two ways and user (installer) select the way at a setup screen ?
you can not setup a Kiosk app using a standard installer. You need to use ADB commands to setup the Provision. See Kiosk tutorial!
 
Upvote 0

Magma

Expert
Licensed User
Longtime User
@DonManfred Thanks for answerss

you can not setup a Kiosk app using a standard installer. You need to use ADB commands to setup the Provision. See Kiosk tutorial!

I know... that's because the error...

But i will provide a guide about installation at the installer-guy ! :)
 
Upvote 0

Magma

Expert
Licensed User
Longtime User
Before close the topic...

At the Erel 1st post:
https://www.b4x.com/android/forum/threads/device-owner-tasklock-kiosk-apps-2017.81765/

Says:
Existing user accounts on the device must first be removed (Settings - Accounts).

We are talking about adminstrator accounts?... because that option is on some tablets Settings->Security->Administrators

We are talking about accounts on Facebook, Google ?

or we are talking about Administrator Users - because already delete them and tried again the command (ofcourse in Android 5+) - got that:

D:\Project-MVT\adb>adb shell dpm set-device-owner mvt.client/anywheresoftware.b4
a.objects.AdminReceiver2


java.lang.IllegalStateException: Trying to set device owner but device is alread
y provisioned.
at android.os.Parcel.readException(Parcel.java:1554)
at android.os.Parcel.readException(Parcel.java:1499)
at android.app.admin.IDevicePolicyManager$Stub$Proxy.setDeviceOwner(IDev
icePolicyManager.java:3202)
at com.android.commands.dpm.Dpm.runSetDeviceOwner(Dpm.java:114)
at com.android.commands.dpm.Dpm.onRun(Dpm.java:82)
at com.android.internal.os.BaseCommand.run(BaseCommand.java:47)
at com.android.commands.dpm.Dpm.main(Dpm.java:38)
at com.android.internal.os.RuntimeInit.nativeFinishInit(Native Method)
at com.android.internal.os.RuntimeInit.main(RuntimeInit.java:257)

WHAT option exactly means Erel (from the post i can understand that means the option got accounts for Facebook, Google etc)... ?

ps: hope not need root device...
 
Last edited:
Upvote 0
Top