qbasic.hlp (Topic list)
Important Notice
The pages on this site contain documentation for very old MS-DOS software, purely for historical purposes. If you're looking for up-to-date documentation, particularly for programming, you should not rely on the information found here, as it will be woefully out of date.
DATE$ Function and Statement
  Contents  Index  Back
──────────────────────────────────────────────────────────────────────────────
The DATE$ function returns the computer's current system date.
The DATE$ statement sets the current system date on your computer.
 
DATE$
DATE$ = stringexpression$
 
    ■ stringexpression$    The date in one of the following forms:
                           mm-dd-yy, mm-dd-yyyy, mm/dd/yy, mm/dd/yyyy.
 
    ■ The DATE$ function returns a string in the form mm-dd-yyyy.
 
Example:
    PRINT DATE$
    DATE$ = "01-01-90"    'Note: The new system date remains in effect until
                          '      you change it again.
    PRINT "Date set to "; DATE$
 
See Also    TIME$