You're going to have to script that, certainly.

You could use robocopy or xcopy or do the whole thing in powershell, but no
native tool provides the logic you want without some form of scripting.


For instance, assuming that you were going to start in the C:\TEMP folder,
and search for "something":

@echo off
 SETLOCAL ENABLEDELAYEDEXPANSION
 for /f "tokens=*" %%v in ('dir /ad /b /s C:\Temp\*.*' ^| FIND /I
"something") do (
   SET @DIR=%~fpv
   ECHO Copying !@DIR!
   XCOPY !@DIR! D:\SomeDestination /S /E /R /Y
 )






* *

*ASB* *http://about.me/Andrew.S.Baker* *Harnessing the Advantages of
Technology for the SMB market…

*



On Wed, Jul 20, 2011 at 12:00 PM, Jeff Bunting <[email protected]>wrote:

> I'm attempting to search for particular words in a directory name (must use
> wildcards!), and, if found, copy the the directory tree while maintaining
> its structure to another directory.
>
> Are there any native tools (or reskit like robocopy) that can accomplish
> this somewhat easily?
>
> thanks,
> Jeff
>
> ~ Finally, powerful endpoint security that ISN'T a resource hog! ~
> ~ <http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/>  ~
>
> ---
> To manage subscriptions click here:
> http://lyris.sunbelt-software.com/read/my_forums/
> or send an email to [email protected]
> with the body: unsubscribe ntsysadmin
>

~ Finally, powerful endpoint security that ISN'T a resource hog! ~
~ <http://www.sunbeltsoftware.com/Business/VIPRE-Enterprise/>  ~

---
To manage subscriptions click here: 
http://lyris.sunbelt-software.com/read/my_forums/
or send an email to [email protected]
with the body: unsubscribe ntsysadmin

Reply via email to