DayTimeDuration Constructor (long, int, int, decimal)DayTimeDuration Constructor (Long, Integer, Integer, Decimal)DayTimeDuration Constructor (long, int, int, decimal)

Initializes a new instance of the DayTimeDurationDayTimeDurationDayTimeDuration structure with the specified duration in days, hours, minutes and seconds.

Syntax

Public Sub New ( _
    days As Long, _
    hours As Integer, _
    minutes As Integer, _
    seconds As Decimal _
)
public DayTimeDuration(
    long days,
    int hours,
    int minutes,
    decimal seconds
)
public:
DayTimeDuration(
    long days, 
    int hours, 
    int minutes, 
    decimal seconds
)
 

Parameters

days

Type: System.Int64System.Int64System::Int64

The number of days.

hours

Type: System.Int32System.Int32System::Int32

The number of hours.

minutes

Type: System.Int32System.Int32System::Int32

The number of minutes.

seconds

Type: System.DecimalSystem.DecimalSystem::Decimal

The number of seconds.

Exceptions

ExceptionCondition
OverflowExceptionOverflowExceptionOverflowException The duration components represent a duration less than MinValueMinValueMinValue or greater than MaxValueMaxValueMaxValue.