1, view the system "Region and Language" format
2, press "Additional settings" to view the time format and date format in the Customize format as follows:
3, after checking the format, in the cmd command line, enter date, displayed as follows:
4, below we in the C packing directory to create a batch file Test01.bat, the code is as follows:
5, C disk directory to create a Test01.bat file
6, double-click to run this bat file can see in the C-packing directory created a 20130110 folder
7. Why do you want to create a folder with the name of the current date? Because some companies need to back up the server's data every day, especially the file server, so we can create batch commands, set up some schedule to make the system run automatically every day, and easy to view, manage, and recover. We want to distribute by date, so just add the Robocopy command to the Test01.bat command above, and copy it to the folder you just created. In this, robocopy of the use of features do not need me to introduce more, in the command line mode, enter: Robocopy/? To see how the command is used, the options we use are these:
Usage:: ROBOCOPY source destination [file [file] ...] [Options]
Source:: Source directory (drive: path or server share path).
Goal:: Target directory (drive: path or server share path).
Files:: Files to copy (name/wildcard: default is "*.*").
/S:: Replicates subdirectories, but does not copy empty subdirectories.
/e:: Replicates subdirectories, including empty subdirectories.
/sec:: Copy the file with security (equivalent to/copy:dats).
/copyall:: Copy all file information (equivalent to/copy:datsou).
/mov:: Move the file (removed from the source after copying).
/move:: Moving files and directories (removed from the source after replication)