[EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
** A week is defined as a seven-day period running from Monday-Sunday.
** Week 1 of any year is defined as the first week containing four days
** of the year, or equivalently the week containing the first Wednesday
** of the year. For
, 2005 5:57 AM
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] Week of the year (UV)
[EMAIL PROTECTED] wrote:
[EMAIL PROTECTED] wrote:
** A week is defined as a seven-day period running from
Monday-Sunday.
** Week 1 of any year is defined as the first week
containing four
days
Dows anybody know how to work out what week of the year you are in?
Regards
Bjorn
---
u2-users mailing list
u2-users@listserver.u2ug.org
To unsubscribe please visit http://listserver.u2ug.org/
Howzit Bjorn
Here is my program to do it:
Louie
*--
PROMPT ''
10*
CRT 'Date to calc week number for : ':;INPUT DATE.INPUT ;* e.g 13/05/2005
IF DATE.INPUT='' THEN STOP
*--
IDATE = ICONV(DATE.INPUT,'D')
YEAR=OCONV(IDATE,'DY')
MY.JULIAN.DATE=OCONV(IDATE,'DJ')
*--
WEEK.NO=0
If I understand the question properly, I believe this will do it:
PRINT INT(OCONV(DATE(),'DJ')/7) +
OCONV((OCONV(DATE(),'DJ')/7:'')['.',2,1],S;'1';'0')
...but be aware that even though we think of a year as having 52 weeks, and
a week is 7 days, 7 * 52 = 364. As far as I know, a year always
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Barry Brevik
Sent: Thursday, October 27, 2005 11:42 AM
To: 'u2-users@listserver.u2ug.org'
Subject: RE: [U2] Week of the year (UV)
If I understand the question properly, I believe this will do it:
PRINT
Certainly the standard is applicable but only if the client is
concerned about the definition of week according to ISO 8601. Some
might, some might not. I was simply sharing some of the issues that
have come up in the projects I've had for calculating the week number,
of which I have had three
, October 27, 2005 2:11 PM
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] Week of the year (UV)
Certainly the standard is applicable but only if the client
is concerned about the definition of week according to ISO
8601. Some might, some might not. I was simply sharing some
But of course! :-)
-Original Message-
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Bill_H
Sent: Thursday, October 27, 2005 4:59 PM
To: u2-users@listserver.u2ug.org
Subject: RE: [U2] Week of the year (UV)
Kevin:
Sorry, I wasn't implying anything other than