Need help fast? Ask Pulse AI and get instant support.

Go back to homepage

Sending script to remove file and then add new file

RD
Ryan Dragon
DSC Logistics

We have Zebra VC80x's and use a program called Velocity.  Right now, I created a package that pushes our configuration file to a specific folder on the Zebra.  If they change the configuration, they typically have a different name, so when I push the new file, it will show both configurations to the user.  I'd like to create a package that will have a pre-install script to delete the old file but unsure how to do it in Android.  Does anyone know the command(s) I need to do this.  

The current file is called DSC v0.15.3L.wldep and I pushed it to this path:  \storage\emulated\0\com.wavelink.velocity\

Is there a simple command I can do to remove this?  or does it not work this way in Android?

Thank you in advance.

7 years ago
Android
ANSWERS
MD
Matt Dermody
7 years ago

Have you consulted the scripting guide in the MobiControl documentation? It has everything you need.

del /sdcard/com.wavelink.velocity/*.wldep

RD
Ryan Dragon
7 years ago

I called Soti and they pointed me in the right direction.  Thanks for the reply.

MD
Matt Dermody
7 years ago

Did they provide you with the same script as above? 

RD
Ryan Dragon
7 years ago

They pointed me to a link that had a bunch of Android commands.  He added I may want to kill the app before sending the file so I created a pre-install script which includes...

kill_application com.wavelink.velocity
del \storage\emulated\0\com.wavelink.velocity\*.wldep

I figured it would be that easy but didn't have a test device in front of me and wasn't sure on the exact syntax for android commands.  That document they sent helps me out a lot with scripting.