Time formatting inside file name
All date/time parameters support a formatting attribute. Formatting attribute is specified after hash (#) symbol.
For example:
  • %{setup-time#%Y} will return year, like: 2011
  • %{setup-time#%m} will return month, like: 02
  • %{setup-time#%Y-%m} will return both year and month, like: 2011-02
Table 1. Formatting codes
Abbreviated weekday name
Full weekday name
Abbreviated month name
Full month name
Day of month as decimal number (01 – 31)
Hour in 24-hour format (00 – 23)
Hour in 12-hour format (01 – 12)
Day of year as decimal number (001 – 366)
Month as decimal number (01 – 12)
Minute as decimal number (00 – 59)
A.M./P.M. indicator for 12-hour clock
Second as decimal number (00 – 59)
Week of year as decimal number, with Sunday as first day of week (00 – 53)
Weekday as decimal number (0 – 6; Sunday is 0)
Week of year as decimal number, with Monday as first day of week (00 – 53)
Year without century, as decimal number (00 – 99)
Year with century, as decimal number
Percent sign
Microseconds as decimal number
Table 2. Examples of time formatting
Format string
%d %b %Y, %A
10 Nov 2004, Wednesday
Note, for all examples, we used the same date/time, which is “10th of November 2004 16:02:01”. This day is a Wednesday.
Read also:
Export as PDF
Copy link