WEEKNUM

WEEKNUM

Synopsis

WEEKNUM (date[,method])

Description

WEEKNUM returns the week number of date according to the given method.

method defaults to 1.

For method=1, week starts on Sunday, and days before first Sunday are in week 0.

For method=2, week starts on Monday, and days before first Monday are in week 0.

For method=150, the ISO 8601 week number is returned.

  • WEEKNUM returns #NUM! if date or method is invalid.
  • This function is Excel compatible, except that Excel does not support ISO 8601 week numbers.

Examples

If A1 contains 12/21/00 then WEEKNUM(A1,2)=51

See also

ISOWEEKNUM.