Work Week Function

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hello,

Looking for a function or procedure to calculate work week based on Monday
as the first day of the week. For example Year (2006)

WW: 1
Date: 1/2/06-1/8/06

WW: 2
Date: 1/9/06-1/15/06


WW:34
Date: 8/21/06-8/27/06


Regards,
 
Try DatePart("ww", MyDateValue, vbMonday)

Note that there's a fourth parameter, as well, that lets you specify the
first week of the year (You can specify 1 to start with the week in which
January 1st occurs, 2 to start with the first week that has at least 4 days
in the new year or 3 to start with the first full week of the year)
 
Thank you Doug.

Douglas J. Steele said:
Try DatePart("ww", MyDateValue, vbMonday)

Note that there's a fourth parameter, as well, that lets you specify the
first week of the year (You can specify 1 to start with the week in which
January 1st occurs, 2 to start with the first week that has at least 4 days
in the new year or 3 to start with the first full week of the year)
 
Back
Top