Copies directories, their subdirectories, and files except hidden and system files. ![]()
Syntax
XCOPY source [ destination ] [ /Y| / -Y ] [ /A | /M ] [ /D:date ] [ /P ] [ /S ] [ /E ] [ /W ]
Frequently Used Switches
/Y Overwrites existing files without prompting.
/-Y Prompts you before overwriting existing files.
/A Copies files with the archive attribute set, doesn't change the attribute.
/M Copies files with the archive attribute set, turns off the archive attribute.
/D:date Copies files changed on or after the specified date. If no date is given, copies only those files whose source time is newer than the destination time.
/P Prompts you before creating each destination file.
/S Copies directories and sub directories excepting the empty ones.
/E Copies directories and sub directories, including empty ones. Same as /S /E. May be used to modify /T.
/W Prompts you to press a key before copying.











