Page 1 of 2

deploying with an external app

Posted: November 22nd, 2020, 5:00 pm
by AriSilva
I have an application (.apk) that I call with an execsystem from inside csentry, thus, I put the .apk in the deploy, and it goes right to the tablet.
But I need to install this apk by hand in the tablet.
Is there a way to install it automatically?

Re: deploying with an external app

Posted: November 22nd, 2020, 7:33 pm
by josh
I can't think of a way to do that from CSEntry. My guess is that Android would not you install an app without getting explicit permission from the user, otherwise that would be a pretty big security hole.

Re: deploying with an external app

Posted: November 23rd, 2020, 6:57 am
by AriSilva
Well, that was my guess also.
Thanks

Re: deploying with an external app

Posted: November 23rd, 2020, 8:09 am
by josh
You could try using

Code: Select all

execsystem("view:<full path to apk>")
. I have not tested it, but in theory it will launch the app installer. It will prompt the user if they want to install the apk file, so it will not be fully automatic but at least you won't have to browse to the file.

Re: deploying with an external app

Posted: November 23rd, 2020, 1:04 pm
by AriSilva
OK, I´ll try it.
But then comes a second question, derived from the previous one:
If the execsystem(.apk) works, it it possible to integrate it into the downloading of the csentry application? (I do not know how, but...)
That is, when creating the deploy, it would have a feature to execute something after being installed in the tablets.
Or, I was thinking about executing it in he menu-control program, not every time, but only if a certain file existed in the directory.
This file would be deleted after the first execution, so, in fact, the installation process would be executed one (or every time a new version was downloaded to the tablets).
What do you think?

Re: deploying with an external app

Posted: November 23rd, 2020, 3:44 pm
by josh
There is no way of running it as part of the deploy but I think your idea of launching it the first time the menu program is run should work. I would probably use loadsetting/savesetting rather than making it based on a file but either would work. That is assuming that the execsystem idea works.

Re: deploying with an external app

Posted: November 23rd, 2020, 4:16 pm
by AriSilva
ok, I´ll give it a try and keep you posted.
I´m not sure the load/save setting scheme would work if I have to update the version installed.
The very first time is easy, but as soon as the setting is done, one way or the other, how do I unflag it in order to reinstall the app?

Re: deploying with an external app

Posted: November 23rd, 2020, 5:34 pm
by josh
Just save the version number as the setting.

Re: deploying with an external app

Posted: November 26th, 2020, 4:33 pm
by AriSilva
Yeah,
That would work in the real running, but not at the test phase, unless I create a new version every time I update it, which would be a pain.
Nevertheless, that you for the tip on running the installation of the apk, it is working perfectly, and saves us a lot of trouble trying to remember the interviewers that they have to reinstall the app.

Re: deploying with an external app

Posted: November 30th, 2020, 12:43 am
by etuser
Dear Ari,

Can you share the batch program the work the .apk trick.

Many thanks,