Liquid XML Data Binder (C++, Java, VB6) / Reference / Visual Basic 6 / Reference / DateTime / VB6 DayOfWeek - DateTime
In This Topic
    VB6 DayOfWeek - DateTime
    In This Topic

    Public Property DayOfWeek As Long
    (read-only)

      Property Description  
        Description The Day of the Week. Sunday = 1, Monday = 2 etc. (Valid Range = 1 to 7).  
        Remarks

    Throws:
    If the type is not one of the following
        DTType_dateTime
        DTType_date

     
        Example

    Code
    Dim dt As New LtXmlComLib21.DateTime

    dt.SetDate 2002, 2, 2
    Debug.Print "Day of week = " & dt.DayOfWeek & " Day of year = " & dt.DayOfYear

    dt.SetDate 2000, 12, 31
    Debug.Print "Day of week = " & dt.DayOfWeek & " Day of year = " & dt.DayOfYear

    Output
    Day of week = 7 Day of year = 33
    Day of week = 1 Day of year = 366