Hey Tony, long time!
Without thinking about it, so I could be mistaken, this is where I
would start.
:SETVAR MYWEEKOFYEAR (HPDOY / 7) + 1
:ECHO !MYWEEKOFYEAR
2
This logic should get you through this year. However, it's probably
more reasonable to make the '+ 1' into a variable, that is set to 1 or 0
depending on if the 7th of Jan is part of the 1st week of the year or
not.
I donno,
--
Michael Anderson
Spring Independent School District
16717 Ella Boulevard
Houston, Texas 77090-4299
office: 281.586.1105
fax: 281.586.1187
-
>>> Tony Gil <[log in to unmask]> 01/07/03 10:47AM >>>
All,
Has anyone written an MPE script which calculates the week number of
the
year using the current day and HPDAY (or any other system variable)?
For
example, today would be the second week of the current year, since the
first
week ended on 1/4/03.
Thanks in advance!
Tony Gil
Sr. Programmer Analyst
Centis Inc.
205 S. Puente Street
Brea, CA. 92821
v: 714-626-2406
f: 714-441-4536
e: [log in to unmask] <mailto:[log in to unmask]>
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
* To join/leave the list, search archives, change list settings, *
* etc., please visit http://raven.utc.edu/archives/hp3000-l.html *
|