New
#1
Batch command to put Template Docx in all subfolders
I need to put a word docx template in over 200 folders that are under one primary folder. Looking for a way to do this without manually saving it in every folder.
I need to put a word docx template in over 200 folders that are under one primary folder. Looking for a way to do this without manually saving it in every folder.
You can do it easily in powershell, changing the 2 bits in red:Code:$Directories=Get-ChildItem "C:\Temp" -Directory -Recurse ForEach ($Directory in $Directories) { Copy-Item "C:\Temp\MyFile.docx" $Directory.FullName }
The top one "C:\Temp" is your primary folder that the subfolders are under.
The bottom one "C:\Temp\MyFile.docx" is the location of document you want to copy - it need not be in same folder it can be somewhere else.
It will look like this when you type it in: