03.05.2013 Views

FLASH® LITE™ 2.x - Adobe Help and Support

FLASH® LITE™ 2.x - Adobe Help and Support

FLASH® LITE™ 2.x - Adobe Help and Support

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Returns<br />

Number - An integer.<br />

Example<br />

The following example initially creates a new Date object, setting the date to May 15, 2004,<br />

<strong>and</strong> uses Date.setMonth() to change the date to June 15, 2004:<br />

var today_date:Date = new Date(2004,4,15);<br />

trace(today_date.getUTCMonth()); // output: 4<br />

today_date.setUTCMonth(5);<br />

trace(today_date.getUTCMonth()); // output: 5<br />

See also<br />

getUTCDay (Date.getUTCDay method), getDay (Date.getDay method)<br />

setUTCSeconds (Date.setUTCSeconds method)<br />

public setUTCSeconds(second:Number, [millisecond:Number]) : Number<br />

Sets the seconds for the specified Date object in universal time <strong>and</strong> returns the new time in<br />

milliseconds.<br />

Parameters<br />

second:Number - An integer from 0 to 59.<br />

millisecond:Number [optional] - An integer from 0 to 999. If you omit this parameter, the<br />

milliseconds field of the specified Date object will not be modified.<br />

Returns<br />

Number - An integer.<br />

Example<br />

The following example initially creates a new Date object, setting the time <strong>and</strong> date to<br />

8:00:00 a.m. on May 15, 2004, <strong>and</strong> uses Date.setSeconds() to change the time to 8:30:45<br />

a.m.:<br />

var my_date:Date = new Date(2004,4,15,8,0,0);<br />

trace(my_date.getUTCSeconds()); // output: 0<br />

my_date.setUTCSeconds(45);<br />

trace(my_date.getUTCSeconds()); // output: 45<br />

330 ActionScript classes

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!