Hi everyone,
I’m looking for a script that can copy specific data/variables like %Phonenumber% to the clipboard.
Does anyone have an idea how to fix this?
Hi everyone,
I’m looking for a script that can copy specific data/variables like %Phonenumber% to the clipboard.
Does anyone have an idea how to fix this?
Hi Marco,
With this limited information I can share one alternative, by using JS for Android devices, you can read data from the file by specify the file's path as following example (.ini file as an example only, you can also use .json, .txt or etc. as well) :
var count = new mobicontrol.io.File('/sdcard/Download/user_name.ini');
var text_read = count.readText();
mobicontrol.log.info('Read info is:' +text_read);
And then you can store and get action by using this data. If this does not work for you, please share your use-case; what is your goal and what do you do by using this to let us help you with our best. Thank you
Zafer
To which clipboard you mean? (the one from the phone or from the console user)
Hi Marco,
Please elaborate your use case. Is everything run within MobiControl Kiosk mode? How will the script get initiated?
If some required data is in the clipboard, how will it be consumed (e.g interactively by device end-user or automatically by a running app/service)? How frequently? Or how quickly the response should be? All these may affect whether the data should be passed via clipboard in the first place.
Hello everyone,
thanks for the input.
The issue is that the current phone number of the device needs to be entered into an application, unfortunately, every time it's used. The idea was that there would be a script in kiosk mode that copies the system variable %Phonenumber% to the clipboard, and the user would just need to go to the field and select paste. Currently, we have a workaround where the phone number is displayed on the Dynamic Lockdown screen, we copy it, and then manually enter it into the application.
There’s probably also a solution here with JavaScript, as Zafer describes. I just thought maybe someone has a simple, quick idea :)
Hi Marco,
Thanks for posting on SOTI Pulse, Thanks Zafer, Rafael and Raymond for responding to the post, your expertise and willingness to help are greatly appreciated!
We request you to please raise a support case at log a case so that our agent can work on your query as quickly as possible.