This document is provided on an "AS IS" basis without warranties of any kind. Smartsite iXperion class libraries may change in future releases.
Sets the time components of the given DateTime.

Namespace: Smartsite.Runtime.Modules
Assembly:  Smartsite.Runtime.Modules (in Smartsite.Runtime.Modules.dll)

Syntax

C#Copy imageCopy Code
[(IsDeterministic = true)]
public static <> SetTime(
	 dt,
	int hour,
	int minutes,
	int seconds
)
Visual Basic (Declaration)Copy imageCopy Code
<(IsDeterministic := True)> _
Public Shared Function SetTime ( _
	dt As , _
	hour As Integer, _
	minutes As Integer, _
	seconds As Integer _
) As (Of )

Parameters

dt
DateTime
A DateTime.
hour
Int32
The hours (0 through 23).
minutes
Int32
The minutes (0 through 59).
seconds
Int32
The seconds (0 through 59).

Return Value

A new DateTime with the same date as the given DateTime, and the time set to the given time component values.

Examples

2007-11-14T12:30:00 Result: 2007-11-14T12:30:00

See Also

Advanced