I have a classroom network where all of the machines have a shared folder following the same pattern. Each share can be accessed as:
\\…\foo\bar\folder
Here, the names foo
, bar
and folder
are fixed, and only the computer name is different.
Eventually I plan to copy files to all of the folders above.
The question is: how do I loop through all of the share names above? In a command shell, I tried:
for %i in (\\*\foo\bar\folder) do echo %i
but that’s not working for me.
Thanks