Date.setYear( ) Method | Flash 5 |
assign the year, relative to 1900 |
A required integer specifying the new year of date. If one or two digits are supplied, the year is assumed to be in the twentieth century (1900s). For example, 1 is the year 1901, and 99 is the year 1999. Three-digit years are assumed to be prior to 1000 A.D. Use four digits to specify the year 2000 and later. A negative number specifies the number of years B.C., not the number of years before 1900.
An optional integer from 0 (January) to 11 (December), not from 1 to 12, representing the new month of the year of date.
An optional integer from 1 to 31, representing the new day of the month of date.
An integer representing the number of milliseconds between the new date and midnight, January 1, 1970.
setYear( ) is identical to setFullYear( ), except that it interprets one- and two-digit years as being relative to 1900, whereas setFullYear( ) interprets them as being relative to 0 A.D.
Date.getYear( ), Date.setFullYear( )