HP3000-L Archives

October 1998, Week 4

HP3000-L@RAVEN.UTC.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Glenn Cole <[log in to unmask]>
Reply To:
Date:
Fri, 23 Oct 1998 13:17:26 -0700
Content-Type:
text/plain
Parts/Attachments:
text/plain (37 lines)
Jim Phillips asks:

> Is there an easy way to determine if today is the last day of the
> current month?

Here's one way:

    Call CALENDAR to get today's date (it's in that wacky compressed format).
    Add 1.

    Pass the result to ALMANAC, and look at the returned MONTH.

    If the current month is different from the returned MONTH,
    then today is the last day.

Then again, I'm not convinced this is any more efficient than
a manual method.


Hmmm, better yet, it looks like you can get away with:

     Add 1 to the day-of-month

     call HPDATEFORMAT or HPDATEVALIDATE (5.5 express 4)

Details on this latter (hopefully much more efficient) solution are at

     < http://jazz.external.hp.com/papers/Communicator/5.5/exp4/cmdate.html >

--Glenn Cole
  Software al dente, Inc.
  [log in to unmask]

.......................................................................

Item Subject: cc:Mail Text

ATOM RSS1 RSS2