I have been using the following command to get the file date. However, the fileDate
variable has been returning blank value ever since we moved to a different server (Windows Server 2003).
FOR /f %%a in ('dir myfile.txt^|find /i " myfile.txt"') DO SET fileDate=%%a
Is there any other more reliable way to get the file date?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…