Home  Contents

date:set

Date/Time Core4 Lua Commands

SYNOPSIS

date::set([year[, month[, day]]])

DESCRIPTION

Changes the stored date value. Values that are not specified or passed as nil are not changed.

ERRORS

Raises an error if date is not a date instance.

EXAMPLE

>  > 
d = clock.newDate(2001, 9, 9) print(d)
2001-09-09
>  > 
d:set(nil, nil, 20) print(d)
2001-09-20

SEE ALSO