YearMonthDuration.Years PropertyYearMonthDuration.Years PropertyYearMonthDuration::Years Property

Gets the years component of the current YearMonthDurationYearMonthDurationYearMonthDuration.

Syntax

Public ReadOnly Property Years As Long
        Get
public long Years { get; }
public:
property long Years {
    long get();
}
 

Property Value

Type: System.Int64System.Int64System::Int64

The years component of this duration. The value can be positive or negative.