DIAdem Help

Method: Year for VBS

  • Updated2024-09-12
  • 1 minute(s) read

Method: Year for VBS

Specifies the year.

vYear = Object.Year(Date)
ObjectVBS
Object with this method. You do not need to specify this object.
DateVariant
Specifies the date.
vYearVariant
Receives the year.

The following example displays the current year:

Dim iMyYear
iMyYear = Year(Now)
Call MsgBox(iMyYear)

Related Topics

DateAdd | DateDiff | DatePart | DateSerial | DateValue | Date | Day | Hour | Minute | MonthName | Month | Now | Second | TimeSerial | TimeValue | Time | Timer | Weekday | WeekdayName | Year