I am trying to get the currnet date so that when I create a file it has the date in it, however this has not been easy !..
I am trying to use this to create the date (see code below). However this this runs it seems to create the Pdate as _03_2009 which is strange as I was expecting 2009_03_30 ?
Can someone tell me what is wrong with the below. I am using this batch files on Windows XP Compuiters only.
FOR /F "TOKENS=1,2 DELIMS=/ " %%A IN ('DATE /T') DO SET mm=%%B
FOR /F "TOKENS=2,3 DELIMS=/ " %%A IN ('DATE /T') DO SET dd=%%B
FOR /F "TOKENS=3* DELIMS=/ " %%A IN ('DATE /T') DO SET yyyy=%%B
set /A dd=%dd%