Name

Calendar

Synopsis

This MustInherit class determines the division and measurement of time in units, such as day, months, years, and eras. It is a MustInherit base class for culture-specific calendar implementations included in this namespace. Derived classes store the specific information about a calendar’s eras, lengths of years and months, and the sometimes esoteric rules for calculating leap years. These properties get used by DateTimeFormatInfo to properly display a date and time string from a specific DateTime value.

Public MustInherit Class Calendar
                  ' Protected Constructors
   Protected Sub New() 
' Public Shared Fields
   Public const CurrentEra As Integer                            // =0
                  ' Public Instance Properties
   MustInherit Public ReadOnly Property Eras As Integer()  
   Overridable Public Property TwoDigitYearMax As Integer  
' Public Instance Methods
   Overridable Public Function AddDays(ByVal time As Date, 
        ByVal days As Integer) As Date  
   Overridable Public Function AddHours(ByVal time As Date, 
        ByVal hours As Integer) As Date  
   Overridable Public Function AddMilliseconds(
        ByVal time As Date, 
        ByVal milliseconds As Double) As Date  
   Overridable Public Function AddMinutes(ByVal time As Date, 
        ByVal minutes As Integer) As Date  
   MustInherit Public Function AddMonths(ByVal time As Date, 
        ByVal months As Integer) As Date  
   Overridable Public Function AddSeconds(ByVal time As Date, 
        ByVal seconds As Integer) As Date  
   Overridable Public Function AddWeeks(ByVal time As Date, ByVal weeks As Integer) As Date MustInherit Public ...

Get VB.NET Core Classes in a Nutshell now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.