Page 1 of 1

Delete a list of items

Posted: 18 Apr 2018 01:18
by armsys
The following code doesn't work.

Code: Select all

// Delete a list of items
  $list = quicksearch(".bak","C:\");
  text $list;
  delete 1,1,$list;

How to delete a list of files?

Re: Delete a list of items

Posted: 18 Apr 2018 01:23
by jupe
If you look at the help for the delete command you will see that it needs the items to be | separated, so it should work like this instead:

Code: Select all

  $list = quicksearch(".bak","C:\", "|");
  text $list;
  delete 1,1,$list;

Re: Delete a list of items

Posted: 18 Apr 2018 01:32
by armsys
Hi Jupe,
It works. Thanks for your help.