The next two functions convert between Julian dates and ASCII strings. Julian dates as defined by astronomers begin at noon GMT; these begin at midnight local time.
char *datstr(DB_Date date)
Return:
This function converts the Julian date represented by date into an ASCII string in the form DD/MM/YYYY.
DB_Date strdat(char *string)
Return:
This function converts string into a Julian date. The argument
should be in the format used by datstr
; if string is
improperly formatted, strdat
returns zero. Note that dates such
as `15/3/89' refer to the first century A.D., not the twentieth.
For example, the interval in days between the events commemorated by the
French and American national holidays is strdat("14/7/1789")
--
strdat("4/7/1776")
.
Go to the first, previous, next, last section, table of contents.