Utilities.DateTimeToString Method

Applies to TestComplete 15.69, last modified on November 13, 2024
This method is obsolete. See the Remarks section below.

Description

The Utilities.DateTimeToString method converts a Variant value storing date and time to a string using the format string specified by the Format parameter and returns the resulting string in the Result parameter.

Declaration

Utilities.DateTimeToString(Result, Format, DateTime)

Result [out]    Required    String    
Format [in]    Required    String    
DateTime [in]    Required    Variant    
Result None

Applies To

The method is applied to the following object:

Parameters

The method has the following parameters:

Result

The string containing the converted date and time.

Format

Specifies the format that should be used for the conversion. For more information on format specifiers, see Date and Time Format Specifiers.

DateTime

Specifies the desired date and time.

Result Value

None.

Remarks

Currently, this function works only in VBScript and DelphiScript scripts.

This method is obsolete. It is supported for backward compatibility only. To convert a date-time value to a string using a special format, use the aqConvert.DateTimeToFormatStr method.

See Also

Working With Dates
Working With Time
Date and Time Format Specifiers
DateTimeToFormatStr Method
DateTimeToStr Method
Today Method
Now Method

Highlight search results