New Date(Int year, Int month, Int day) : Date « System « VB.Net by API






New Date(Int year, Int month, Int day)

  


Public Class Tester
    Public Shared Sub Main
        Dim thirdOfJuly As Date = #7/3/1776 11:59:59 PM#
        Dim fourthOfJuly As New Date(1776, 7, 4)
        Dim inTheMorning As New Date(1776, 7, 4, 9, 45, 30)

        Console.WriteLine( _
           "The 3rd and 4th of July, 1776..." & _
           vbNewLine & vbNewLine & _
           "#7/3/1776 11:59:59 PM# ... " & _
           thirdOfJuly.ToString & vbNewLine & _
           "New Date(1776, 7, 4) ... " & _
           fourthOfJuly.ToString & vbNewLine & _
           "New Date(1776, 7, 4, 9, 45, 30) ... " & _
           inTheMorning.ToString)
    End Sub
End Class

   
    
  








Related examples in the same category

1.New Date(Int year, Int month, Int day, Int hour, Int minute)
2.Date.AddDays
3.Date.AddMilliseconds
4.Date.AddMonths
5.Date.AddYears
6.Date.DayOfYear
7.Date.Millisecond
8.Date.Parse
9.Date.ToLongDateString
10.Date.ToLongTimeString
11.Date.ToOADate
12.Date.ToShortDateString
13.Date.ToShortTimeString
14.Date.ToString
15.Date.ToUniversalTime
16.Date.op_Subtraction