DateSerial Function

     

  • DateSerial function returns the Date
  • DateSerial function consits of 3 Functional Arguments (i)Year (ii) Month (iii)Date
  •  

    Download The Workbook

     

    Sub Create_Dates_With_DateSerial()

    Dim r As Integer
    r = 2
    Dim Y As Integer, M As Integer, D As Integer
    Do Until r = 7
    Y = Cells(r, 1).Value
    M = Cells(r, 2).Value
    D = Cells(r, 3).Value

    Cells(r, 4).Value = DateSerial(Y, M, D)
    r = r + 1
    Loop

    End Sub