Delete backup files using "filesystem.deletefile" node

Hi All,

Not sure why this node is not doing what it is suppose to do (to delete the files in the list)
I was able to filter the .000X till the last node it came out as Null.

Thanks

Hi Dz Architect,

Could you show the rest of the script?
Are you actually entering a path in that node or is it a filename?

Null is a valid output here - you only get something other than null if the file failed to delete. You can use a FileSystem.FileExists after your wait for method of choice to confirm the file was deleted.

delete file

1 Like

Hi

this is the full script with the packages used.

Thanks

1 Like

HI Jacob,

thanks for confirming that this node actually does what it needs to be doing, but I am just wondering when the backup files are deleted then I run the script again it still populates them as they are still there …

As you can see below the 3 files don’t exist anymore but running the script still show them as they are there…

Update… when I actually close the script and open it again and it runs with only the existing files.
sorry but running the script again (and seeing the backup files there) threw me off thinking the script not doing the deletion.

I’m trying to do this as well, I can’t find a RegEx node and I don’t know how to make one. Where did this come from?

Nevermind, figured it out. I used a Code Block with the line “([.][0-9][0-9][0-9][0-9][.])”; instead.

Ok, cool.