Utilities.ReplaceTime Method

Applies to TestComplete 15.63, last modified on April 10, 2024
This method is obsolete. See the Remarks section below.

Description

The Utilities.ReplaceTime method changes the value of the DateTime parameter so that it has the same time as the NewTime parameter. The date portion of DateTime remains untouched. ReplaceTime supports negative dates (before 1900).

Declaration

Utilities.ReplaceTime(DateTime, NewTime)

DateTime [in, out]    Required    Variant    
NewTime [in]    Required    Variant    
Result None

Applies To

The method is applied to the following object:

Parameters

The method has the following parameters:

DateTime

The Variant value holding the date and time value whose time part should be changed. This parameter also holds the changed value.

NewTime

The Variant value storing the new time.

Result Value

None.

Remarks

The ReplaceTime function does not work in JScript, C++Script and C#Script languages, since these languages do not support parameters of the out type.

This method is obsolete. It is supported for backward compatibility only. To modify the time part of a DateTime value, use the aqDateTime.SetTimeElements method.

See Also

Working With Time
SetTimeElements Method
SetDateElements Method
Now Method
Time Method
StrToTime Method
StrToDateTime Method

Highlight search results