Date and Time Stamps

Create date and/or time stamps as Substitute Text Actions or embed the date/time syntax within larger Substitute Text or Substitute Content Actions. Different Actions can be created to substitute the date and/or time in different formats and with different content. Note that the date/time commands will not work within Scripting Actions, only in Substitutions. See video:

 

Usage


Here are example formats using the date and time formatting syntax detailed below.

${datetime %B %d, %Y} Delivers: August 10, 2016

${datetime %d %B, %Y} Delivers: 10 August, 2016

${datetime %y-%m-%d} Delivers: 16-08-10

${datetime %d-%m-%Y} Delivers: 10-08-2016

${datetime %I:%M %p} Delivers: 02:31 PM

${datetime %H:%M:%S} Delivers: 14:31:19

Date Time - Action: ${datetime %B %d, %Y %I:%M %p} Delivers format: August 10, 2016 02:31 PM

Date Time Format Syntax


The following syntax is used in the Action field to substitute the current date and/or time in various formats. NOTE: The formats that include "#" are specific to Microsoft Windows.

%a - Abbreviated weekday name.

%A - Full weekday name.

%b - Abbreviated month name.

%B - Full month name.

%c -Date and time representation appropriate for locale. Use %#c for long date and time representation, appropriate to current locale.

%d - Day of month as decimal number (01 – 31). Use %#d to remove leading zeros (if any).

%H - Hour in 24-hour format (00 – 23). Use %#H to remove leading zeros (if any).

%I - Hour in 12-hour format (01 – 12). Use %#I to remove leading zeros (if any).

%j - Day of year as decimal number (001 – 366). Use %#j to remove leading zeros (if any).

%m - Month as decimal number (01 – 12). Use %#m to remove leading zeros (if any).

%M - Minute as decimal number (00 – 59). Use %#M to remove leading zeros (if any).

%p - Current locale's A.M./P.M. indicator for 12-hour clock.

%S - Second as decimal number (00 – 59). Use %#S to remove leading zeros (if any).

%U - Week of year as decimal number, with Sunday as first day of week (00 – 53). Use %#U to remove leading zeros (if any).

%w - Weekday as decimal number (0 – 6; Sunday is 0). Use %#w to remove leading zeros (if any).

%W - Week of year as decimal number, with Monday as first day of week (00 – 53). Use %#W to remove leading zeros (if any).

%x - Date representation for current locale. Use %#x for long date representation, appropriate to current locale.

%X - Time representation for current locale.

%y - Year without century, as decimal number (00 – 99). Use %#y to remove leading zeros (if any).

%Y - Year with century, as decimal number. Use %#Y to remove leading zeros (if any).

%z, %Z - Time-zone name or abbreviation; no characters if time zone is unknown.

%% - Percent sign.

Tags: date, stamps, time