How to confirm file existence?

General discussions about Automagic and automation in general

Moderator: Martin

Post Reply
User avatar
Scott
Posts: 24
Joined: 12 Dec 2015 00:09

How to confirm file existence?

Post by Scott » 15 Dec 2015 02:14

Is there a way to confirm the presence of a file?
Samsung Galaxy S9+ (unrooted and cannot/will not root), Android 9.0
Latest stable Automagic version, always

User avatar
Martin
Posts: 4468
Joined: 09 Nov 2012 14:23

Re: How to confirm file existence?

Post by Martin » 16 Dec 2015 20:01

Hi,

You can either use action Init Variables File Info and check variable file_exists afterwards or you can use script function existsFile("/storage/emulated/0/file.txt").

Regards,
Martin

Post Reply