Date Function

Description:

This function returns the formatted current time value according to the supplied format argument.

Format:

result = DATE(FormatString)

Parameter:

FormatString

The FormatString argument consists of one or more codes listed below:

%a Abbreviated weekday name.
%A Full weekday name.
%b Abbreviated month name
%B Full month name.
%c Local date and time representation.
%d Day of the month as decimal number (01 – 31).
%H Hour in 24-hour format (00 – 23).
%I Hour in 12-hour format (01 – 12).
%j Day of the year as decimal number (001 – 366).
%m Month as a decimal number (01 – 12).
%M Minutes as a decimal number (00 – 59).
%p Current location's A.M./P.M. indicator for 12-hour clock.
%S Seconds as a decimal number (00 – 59).
%s Seconds elapsed since midnight (00:00:00), January 1, 1970.
%F Milliseconds as a decimal number (000 – 999).
%f Milliseconds elapsed since midnight (00:00:00), January 1, 1970.
%U Week of the year as a decimal number, with Sunday as the first day of week (00 – 53).
%w Weekday as a decimal number (0 – 6; Sunday is 0).
%W Week of the year as a decimal number, with Monday as the first day of week (00 – 53).
%x Local date representation.
%X Local time representation.
%y Year without a century, as a decimal number (00 – 99).
%Y Year with a century, as a decimal number.
%z, %Z Either the time-zone name or time zone abbreviation, depending on registry settings; no characters if the time zone is unknown.
%% Percent sign.

Example:

STRING szDate;

szDate = Date("Current Date = %A, %d %B %Y, %H:%M:%S");
log szDate;

Output:

Current Date = Tuesday, 27 June 2006, 14:11:45





Go back to the Learning center:


Copyright © AgileLoad. All rights reserved.
Agile Load testing tool| Contact AgileLoad | Terms of Use | Sitemap