[Date Prev][Date Next][Subject Prev][Subject Next][ Date Index][ Subject Index]

Re: Putting The Date In A Variable



Hey, Robert, good to hear from you! Been soakin' up rays? ... I forget how I
discovered VN$DA[mask]; just playing around I guess. VN$DZ is useful!
Amazing, isn't it, what those TTG programmers think up and then keep to
themselves?! BTW, I slipped your WEEKDAY.FRM code into DEADLINE a while back
-- with credit to you and Zeller, of course. I've used a DOS equivalent of
WEEKDAY for years: DOW.COM. It's minuscule and nclosed. (There must be a
nifty Greek derivative for that sort of apples-and-oranges juxtaposition.) DOW
returns an ERRORLEVEL code from 0 to 6 depending on the Day_Of_Week (Sunday to
Saturday). BATch file usage looks like something like this:

dow for %%x in (0 1 2 3 4 5 6) do if errorlevel %%x goto %%x
:0 echo It's Sunday goto End
:1 echo It's Monday goto End [...]
:6 echo It's Saturday
:End

(For some reason the 's aren't displaying properly in the BATch example,
but you get the idea.) This opens up some highly useful possibilities for
AUTOEXEC.BAT or any BATch file. WEEKDAY.FRM does the same for
STARTUP.INT|XWSTART.INT, etc. etc. It would be nice to have an OS/2
equivalent, wouldn't it? It's probably out there. Speaking of OS/2, there's a
relatively new BBS in Seattle called Moonflower (509-891-0250) that's worth a
look. Not bad selection of DOS and Windoze files, too. Bye for now.

*Enclosed File: dow.com