标签:desktop date 桌面 exp windows soft software 调用 echo
1,日期和时间
echo %date:~0,4%年%date:~5,2%月%date:~8,2%日 %time:~0,8%
2,获取桌面地址
for /f "tokens=2,*" %%i in (‘reg query "HKCU\Software\Microsoft\Windows\CurrentVersion\Explorer\Shell Folders" /v "Desktop"‘) do (
set desk=%%j
)
将桌面地址赋值给desk,如果下面要调用的话,直接调用%desk%
标签:desktop date 桌面 exp windows soft software 调用 echo
原文地址:http://www.cnblogs.com/Jian-Zhang/p/6063738.html