Communicator 3000 MPE/iX Release 6.0 (Platform Software Release C.60.00) (30216-90269)

Chapter 9 131
Year 2000 Enhancements
New Date Intrinsics for MPE/iX
If an invalid date is passed, on return from the intrinsic
its contents will be UNKNOWN. For the “HP Standard
Formats,” if special values in the table, “Special Date
Values,” are passed for date parameter, on return from
the intrinsic, the value of the string will be
appropriately initialized. For example, for the date type
18, the initialized values for different special date
values are as follows:
If the character array passed does not have enough
space to hold the special values or the formatted date,
the behavior is undefined.
fmtdatelen is a 32 bit integer by reference (required).
On input, it is the length of the formatspec parameter.
On return, it represents the number of characters
HPDATEFORMAT placed into fmtdate.
status is the HPE_STATUS parameter through which the error
codes are returned. A value of 0 indicates no error and
no warnings.
cutoff is a 32-bit signed integer by value (optional).
This is used in validating and converting from two-digit
to four-digit years. (See HPDATECONVERT
documentation for more information on the cutoff
parameter).
HPDATEDIFF
This intrinsic determines the number of days that separate two given
dates.
Syntax
I32V * * I32 I32 I32V
HPDATEDIFF(datecode, firstdate,seconddate,diffindays,status,cutoff)
Date Value Returned Contents
00000000 “UNKNOWN”
00000101 “INVALID”
00000102 “NEVER”
00000103 “NEEDED”
00000104 “EXPIRED”
00000105 “ILLEGAL