Month

Returns a whole number between 1 and 12, inclusive, representing the month of the year.

Syntax

MonthName(month(Now))

The month argument is any expression that can represent a date. If that date contains Null, then Null is returned.

Example

This example returns the current month:

Dim MyVar = Month(Now)

MyVar contains the number corresponding to the current month.

This example returns "1":

MonthName("01-01-2016")