Batch Script to delete certain folders in parent folder

Discussion forum for all Windows batch related topics.

Moderator: DosItHelp

Post Reply
Message
Author
billstaub
Posts: 1
Joined: 23 Sep 2016 01:40

Batch Script to delete certain folders in parent folder

#1 Post by billstaub » 23 Sep 2016 01:48

Hi there,
I am trying to get a solution for above problem and I have no luck :-(.
I need to have a batch file which moves to the parent folder and delete all files and directories containing a substring 'abc-client' except the one the file is stored in. I tried some for loops and some find with regex but no luck so far. Can you advice? I don't want to use powershell or so just plain dos commands... THANKS A LOT!

Squashman
Expert
Posts: 4486
Joined: 23 Dec 2011 13:59

Re: Batch Script to delete certain folders in parent folder

#2 Post by Squashman » 23 Sep 2016 06:15

billstaub wrote:except the one the file is stored in.

Can you clarify that.

Post Reply