Here is a solution how to create a folder with the name of the current date. You maybe want to perform a backup or another task using this option.
Create a new batchfile *.bat.
We are first going to create variables from the date:
FOR /F "tokens=1-4 DELIMS=/ " %%F IN ('date /T') DO (set v_date=%%F%%G%%H)
After this, you can create some folders on your harddisk that have the name of month/year (var %monthyear%) or day/month/year (var %daymonthyear%). I made a folder for every month and inside these a folder for every day, so I can easily navigate and find my backups.
Now lets create these folders:
Now, you can perform a backup inside these folders:
xcopy "C:Documents" "C:backup%monthyear%%daymonthyear%Documents" /s
xcopy "C:Program Files" "C:backup%monthyear%%daymonthyear%Program Files" /s