Quantcast
Channel: Windows PowerShell forum
Viewing all articles
Browse latest Browse all 21975

search multiple folders for files with same name and create single file

$
0
0

 I have a project where I need to search multiple folders for a file name and when found append data from each file to a single input file.

 Example

root folder to start search
\\servera\sales

\\servera\it\salesa\cmmstr.txt
\\servera\it\salesb\cmmstr.txt
\\servera\it\salesc\cmmstr.txt

 I need to create a a single cmmstr.txt on the root folder. I would like it to be able to run this with parms to pass in folders to search and file names to search and single file name to create. I'm going to have a least 10 differnt files to search for and create output file for. The folders to search
will somewhat be static.

 Thanks.

 


Viewing all articles
Browse latest Browse all 21975

Trending Articles