TimeWithZone Constructor (int, int, decimal, TimeZone?)TimeWithZone Constructor (Integer, Integer, Decimal, Nullable(Of TimeZone))TimeWithZone Constructor (int, int, decimal, Nullable<TimeZone>)

Initializes a new instance of the TimeWithZoneTimeWithZoneTimeWithZone structure with the specified hour, minute, second and time zone components.

Syntax

Public Sub New ( _
    hour As Integer, _
    minute As Integer, _
    second As Decimal, _
    timeZone As Nullable(Of TimeZone) _
)
public TimeWithZone(
    int hour,
    int minute,
    decimal second,
    Nullable<TimeZone> timeZone
)
public:
TimeWithZone(
    int hour, 
    int minute, 
    decimal second, 
    Nullable<TimeZone> timeZone
)
 

Parameters

hour

Type: System.Int32System.Int32System::Int32

The hour component.

minute

Type: System.Int32System.Int32System::Int32

The minute component.

second

Type: System.DecimalSystem.DecimalSystem::Decimal

The second component.

timeZone

Type: System.Nullable<T>System.Nullable(Of T)System::Nullable<T>

The time zone (can be null a null reference (Nothing in Visual Basic) nullptr).

Exceptions

ExceptionCondition
ArgumentOutOfRangeExceptionArgumentOutOfRangeExceptionArgumentOutOfRangeException minute or second are not between 0 and 59 or hour is not between 0 and 23 (24 if minute and second are zero).