Join Wintertainment 2021 to share your stories, have fun, earn community badges, and more!

Utilities.ShortDateFormat Property

Applies to TestComplete 15.10, last modified on December 07, 2021
This property is obsolete. See the Remarks section below.


Use the Utilities.ShortDateFormat property to specify the format string that is used to convert a date value to a short string. For information about format specifiers, see Date and Time Format Specifiers.



Read-Write Property String

Applies To

The property is applied to the following object:

Property Value

The format string that is used to convert a date value to a short string.

By default, ShortDateFormat holds the value specified by Regional Settings in the Windows Control Panel. To restore this value, call the GetFormatSettings method.


Utilities.ShortDateFormat is obsolete and is supported for backward compatibility only. To get or set the short date format, use the aqEnvironment.GetLocaleInfo and aqEnvironment.SetLocaleInfo functions with LOCALE_SSHORTDATE as the second parameter.

JavaScript, JScript

var short_date_format = aqEnvironment.GetLocaleInfo(LOCALE_USER_DEFAULT, LOCALE_SSHORTDATE);


short_date_format = aqEnvironment.GetLocaleInfo(LOCALE_USER_DEFAULT, LOCALE_SSHORTDATE)


short_date_format = aqEnvironment.GetLocaleInfo(LOCALE_USER_DEFAULT, LOCALE_SSHORTDATE)
Log.Message short_date_format


short_date_format := aqEnvironment.GetLocaleInfo(LOCALE_USER_DEFAULT, LOCALE_SSHORTDATE);

C++Script, C#Script

var short_date_format = aqEnvironment["GetLocaleInfo"](LOCALE_USER_DEFAULT, LOCALE_SSHORTDATE);

Or, if you want to convert date values using locale settings, use the methods of the aqDateTime object. They use locale-specific date formats when parsing values.

See Also

Working With Dates
Date and Time Format Specifiers
Today Method
Now Method
Time Method
DateTimeToStr Method
StrToDateTime Method
StrToDate Method
StrToTime Method

Highlight search results