/T Get current date and time.
And It will modify follow environment variable.
year,mon,day,wday
hour,min,sec
/C Get the first CDRom.
And It will modify follow environment variable.
CDRom
/D It will modify follow environment variable.
year,mon,day,wday
/G:n,filename
Get the String from the text file.
The String must be short then 2048 Byte!
It will modify follow environment variable.
GetString,TheString
比较12和13,并显示结果
@echo off
getinfo /cmp:12,13
if errorlevel 2 goto big
if errorlevel 1 goto small
if errorlevel 0 goto equ
goto end
:big
echo x bigger than y
goto end
:small
echo x smaller than y
goto end
:equ
echo x = y
:end
判断今天的日期是否跟设定的日期相同
@echo off
getinfo /t
set today=%Year%%Mon%%Day%
getinfo /cmp:%today%,20051016
if errorlevel 2 goto big
if errorlevel 1 goto small
if errorlevel 0 goto equ
goto end