%tempfile% (can be used with indexes: %tempfile1%, %tempfile2%, etc.)
2.0
Will be replaced by name of a temporary file.
%tempfiledel% (can be used with indexes: %tempfiledel1%, %tempfiledel2%, etc.)
2.0
Will be replaced by name of a temporary file. The temporary file will be deleted when task execution is complete.
%tempfilelog% (can be used with indexes: %tempfilelog1%, %tempfilelog2%, etc.)
2.0
Will be replaced by name of a temporary file. The temporary file content will be added to the log file when task execution is complete.
%tempfilelogdel% (can be used with indexes: %tempfilelogdel1%, %tempfilelogdel2%, etc.)
2.0
Will be replaced by name of a temporary file. The temporary file content will be added to the log file and the temporary will be deleted when task execution is complete.
Standard variables
%actionname%
6.0
Will be replaced by name of the task.
%actiontime%
2.0
Will be replaced by time of start of task execution.
%actionschedule%
2.0
Will be replaced by name of the action that caused task execution.
%actionsource%
2.0
Will be replaced by action source information.
%actionsourceextra%
2.0
Will be replaced by action source extra information.
%lasterrorcode%
2.0
Will be replaced by LastErrorCode. This value is the error code of the previous action. You can find its meanings in the corresponding shortcut type description.
%lastexitcode%
2.0
Will be replaced by LastExitCode. This value is the exit code of the previous action. You can find its meanings in the corresponding shortcut type description.
Definitions
%datetime% (can be used with %datetime% format specifiers: %datetime:yyyy-MM-dd HH-mm-ss%, etc.)
6.0
Will be replaced by current date or time.
%random% (can be used with %random% format specifiers: %random:nnnnnn%, etc.)
6.0
Will be replaced by random text.
Variables
Variable name defeined in a SET VARIABLE statement, enclosed in percent signs.
6.0
Will be replaced by variable value.
All editions
Variable definition
Introduced in version
Description
Environment variables
Environment variable name enclosed in percent signs.
2.0
Will be replaced by variable value.
%% (can be used to pass environment variables to command line without their unwanted expansion. For example, %%USERNAME%% will be passed as %USERNAME%).
6.0
Will be replaced by percent sign.
%datetime% format specifiers
Format specifier
Meaning
longdate
Long date pattern in system format.
shortdate
Short date pattern in system format.
time
Time date pattern in system format.
zz
Name of current time zone.
z
GMT offset of current time zone.
dddd
Long day of week.
ddd
Short day of week.
dd
Day of week, two digits always.
d
Day of week, one or two digits.
MMMM
Long month name.
MMM
Short month name.
MM
Month, two digits always.
M
Month, one or two digits.
yyyy
Year, four digits.
yyy
Year, four digits.
yy
Last two digits of the year, two digits always.
y
Last two digits of the year, one or two digits.
hh
Hour in 12-hour format, two digits always.
h
Hour in 12-hour format, one or two digits.
HH
Hour in 24-hour format, two digits always.
H
Hour in 24-hour format, one or two digits.
mm
Minutes, two digits always.
m
Minutes, one or two digits.
sss
Milliseconds, 1-3 digits.
ss
Seconds, two digits always.
s
Seconds, one or two digits.
tt
Long AM/PM.
t
Short AM/PM.
\
The subsequent character will be interpreted as "any text" (see below).
any text
Any characters that do not match to the above format specifiers. Will remain unchanged.
%random% format specifiers
Format specifier
Meaning
d
Random digit.
a
Ramdom alpha character.
A
Ramdom capital alpha character.
n
Ramdom alphanumeric character.
N
Ramdom capital character.
\
The subsequent character will be interpreted as "any text" (see below).
any text
Any characters that do not match to the above format specifiers. Will remain unchanged.
Leave a Reply
You must be logged in to post a comment.