[<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
 __PACKDATE
 Pack a date formatted variable to a word
------------------------------------------------------------------------------

 Function:
 __PACKDATE:FAR

 Description:
 This function takes a variable pointed to by DX:AX and in the form
 YYYYMMDD (The Internal Clipper Date format), and returns the date
 compressed in a word in AX. Dates must be after 1/1/1980! The compressed
 dates are the dates as DOS uses them.

 Example:
 if you would want a function, let's say Date2Dos() that converts a
 Clipper date var to a DOS word, you could do as follow:

 Date2Dos(dVar) --> nDOSdateValue

 mov    ax,1
 push   ax
 call   __PARDS
 add    sp,2
 call   __PACKDATE
 push   ax
 call   __RETNI
 add    sp,2
 ret

 Note that XPpackDate() does it slightly differently, it converts AX to a
 character and makes sure it can be used for comparing values.

See Also: __PACKTIME __UNPACKDATE
This page created by ng2html v1.05, the Norton guide to HTML conversion utility. Written by Dave Pearson