WeekdayName

Converts an expression to a whole number that represents the day of the week.

Syntax

WeekdayName(weekday[,abbreviate[,firstdayofweek]])

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

Argument Description
weekday Any expression that represents a date. If that date contains Null, then Null is returned.
abbreviate Boolean value that indicates if the weekday name is to be abbreviated. If this argument is omitted, the default value of False is used. The weekday name is not abbreviated.
firstdayofweek Constant that specifies the first day of the week. If omitted, vbSunday is used. The values are:
  • VbUseSystem or 0

    Use National Language Support (NLS) API setting

  • vbSunday or 1
  • vbMonday or 2
  • vbTuesday or 3
  • vbWednesday or 4
  • vbThursday or 5
  • vbFriday or 6
  • vbSaturday or 7

Example

This example returns "1":

WeekdayName(Weekday("01 January 2012"))

This example returns "7":

WeekdayName(Weekday("01-01-2012",2))