Execute script using a Kiosk home screen item

Solved

I have a device locked down with a kiosk that allows a few apps. Now I would like to add a new button that executes a script when pressed.

I have added a screen item with type "script://", but when I press it on the device I get an error message saying "Script execution failed". 

Perhaps I am using the item the wrong way. Could someone point me in the right direction as to how to add the script I wish to execute to the home screen item?

Thank you.

2 years ago
SOTI MobiControl
ANSWERS
MD
Matt Dermody Diamond Contributor
2 years ago

In my experience the script needs to be present on the device in the form of a .cmd file. You can then link to that script file in order to execute it. I would recommend first sending the script manually to a test device from the console to verify that the script is functional. Then save that to a .cmd file. Then deploy that to the device. Then link to it in your kiosk based on where you deployed it to. 

Solution
AW
Adam Williams
2 years ago

Hi Matt,

This might also be interesting to one of my use cases. What is the syntax for this? 

Say the cmd file is saved at /sdcard/

Is it simply script://sdcard/myscript.cmd ?

Thanks
Adam

MD
Matt Dermody Diamond Contributor
2 years ago

That would likely work. Although you might need ///sdcard with 3 slashes. I've also used:

script://%sdcard%myscript.cmd
AW
Adam Williams
2 years ago

Appreciate it, thanks Matt.

A
AMMOD@SOTI
2 years ago

Hi Rick,

Thank you for posting on SOTI Pulse. We appreciate Matt's response and the guidance provided.

We're glad to hear that you have found the answers you were looking for.

If you have any further queries or encounter any challenges related to this issue, please don't hesitate to let us know. We are here to assist you.

Kind regards,

Technical Support | SOTI Inc. |1.905.624.9828 | support@soti.net | www.soti.net |