Create a date and time stamped folder from dos cmd prompt

ok so you need to create a directory based on the current time and date, a timestamp if you will.

its easy, type thisĀ into your cmd window …

mkdir %date:~-4,4%%date:~-7,2%%date:~0,2%-%time:~0,2%%time:~3,2%%time:~6,2%

this will give you a directory named like YYYYMMDD-HHMMSS

Enjoy.

Share and Enjoy: These icons link to social bookmarking sites where readers can share and discover new web pages.
  • Digg
  • del.icio.us
  • DZone
  • MisterWong
  • Reddit
  • Technorati

0 Responses to “Create a date and time stamped folder from dos cmd prompt”


  1. No Comments

Leave a Reply