robocopy transfer file and not folder
See: Robocopy /?
Usage : ROBOCOPY source destination [file [file]...] [options]
robocopy c:\folder d:\folder transfer_this.txt
According to the Wikipedia article on Robocopy:
Folder copier, not file copier
Robocopy syntax is markedly different from standard copy commands, as it accepts only folder names as its source and destination arguments. File names and wild-card characters (such as
*.*
) are not valid source or destination arguments. Files may be selected or excluded using the optional filespec filtering argument. Filespecs can only refer to the filenames relative to the folders already selected for copying. Fully-qualified path names are not supported.For example, in order to copy the file
foo.txt
from directoryc:\bar
toc:\baz
, one could use the following syntax:robocopy c:\bar c:\baz foo.txt