You are here: Development Standards > Routines > General Routines > GENDATE

# GENDATE

GENDATE is a general routine that calls GENDATE.PUB to validate a date. GENDATE occupies lines 9000–9099. Merge it into a program only if the program must validate a date field without using GENINPUT.PUB. Most programs should use GENINPUT.PUB instead of calling GENDATE.PUB directly.

Variable | Description
X$ | Date in string format. The date string is reformatted after it is truncated.
X1$ | Date mask for date
X0 | Row of date field on screen (ignored if X3 is not 2)
X1 | Column of date field on screen (ignored if X3 is not 2)
X3 | Input field type, normally 2 for string with a mask
X | Julian date of X$. These values are returned if a problem is found: -1 - a blank date -9 - an invalid date