Determine the ISO 8601 week number for a particular date.
Namespace:
NetQuarry
Assembly:
EAP.Core (in EAP.Core.dll) Version: 2.0.0.0 (4.6.8.0)
Syntax public static int WeekNumber(
DateTime dt
)
Public Shared Function WeekNumber (
dt As DateTime
) As Integer
Parameters
- dt
- Type: SystemDateTime
The date in question.
Return Value
Type:
Int32The ISO 8601 week number for the specified date.
Remarks
Every workweek has its own number. In Europe this is very often used.
There is an ISO 8601 standard which describes how this number is calculated:
Week 01 of a year is per definition the first week that has the Thursday in this year,
which is equivalent to the week that contains the fourth day of January.
See Also