10/18/23, 10:55 AM Format Codes for the Time Format String - NI
PRODUCT DOCUMENTATION LABVIEW PROGRAMMING REFERENCE MANUAL ...
FORMAT CODES FOR THE TIME FORMAT STRING
Format Codes for the Time Format String
Updated 2023-08-14 1 minute(s) read LabVIEW API Reference LabVIEW G
The Format Date/Time String function calculates the date and time
and formats the output string according to the following format codes.
Format
Value
Code
<%a> abbreviated weekday name (for example Wed)
<%A> full weekday name (for example Wednesday)
<%b> abbreviated month name (for example Jun)
<%B> full month name (for example June)
<%c> locale-specific default date and time
<%d> day of month (01–31)
<%H> hour (24-hour clock) (00–23)
<%I> hour (12-hour clock) (01–12)
<%j> day number of the year (001–366)
<%m> month number (01–12)
<%M> minute (00–59)
<%p> AM or PM flag
<%S> second (00–59)
<%
<digit> fractional seconds with <digit> precision
u>
week number of the year (00–53), with the first Sunday
<%U>
as the first day of week one; 00 represents the first week
weekday as a decimal number (0–6), with 0
<%w>
representing Sunday
week number of the year (00–53), with the first Monday
<%W>
as the first day of week one; 00 represents the first week
<%x> locale-specific date
<%.1x> long date format
<%.2x> abbreviated long date format
<%X> locale-specific time
year within century (00–99); when you scan the
numbers, numbers (00–68) represent years in the
<%y> twenty-first century (2000–2068) and numbers (69–
99) represent years in the twentieth century (1969–
1999)
<%Y> year, including the century (for example, 1997)
[Link] 1/2
10/18/23, 10:55 AM Format Codes for the Time Format String - NI
Format
Value
Code
difference between locale time and universal time
<%z>
(HH:MM:SS)
time zone name or abbreviation, depending on the
<%Z>
operating system locale settings
Parent topic: String
Previous Next
ASCII Codes Carriage Return Constant
[Link] 2/2