| www.delorie.com/djgpp/doc/libc-2.01/libc_144.html | search |
#include <dos.h> unsigned int _dos_setdate(struct dosdate_t *date);
This function sets the current date. The dosdate_t structure is as follows:
struct dosdate_t {
unsigned char day; /* 1-31 */
unsigned char month; /* 1-12 */
unsigned short year; /* 1980-2099 */
unsigned char dayofweek; /* 0-6, 0=Sunday */
};
dayofweek field has no effect at this function call.
See section _dos_getdate. See section _dos_gettime. See section _dos_settime.
Returns 0 if successful and non-zero on error (and sets errno=EINVAL).
struct dosdate_t date;
date->year = 1999;
date->month = 12;
date->day = 31;
if ( !_dos_setdate(&date) )
puts("It was a valid date.");
Go to the first, previous, next, last section, table of contents.
| prev next webmaster | delorie software privacy |
| Copyright © 1997 | Updated Apr 1997 |