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

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

trace("x is not undefined");<br />

}<br />

trace("typeof (x) is "+typeof (x));<br />

if (null == undefined) {<br />

trace("null <strong>and</strong> undefined are equal");<br />

} else {<br />

trace("null <strong>and</strong> undefined are not equal");<br />

}<br />

The following result is displayed in the Output panel.<br />

The value of x is undefined<br />

x is undefined<br />

typeof (x) is undefined<br />

null <strong>and</strong> undefined are equal<br />

Global Functions<br />

This section contains a set of built-in functions that are available in any part of a SWF file<br />

where ActionScript is used. These global functions cover a wide variety of common<br />

programming tasks such as working with data types (Boolean(), int(), <strong>and</strong> so on),<br />

producing debugging information (trace()), <strong>and</strong> communicating with Flash Player or the<br />

browser (fscomm<strong>and</strong>()).<br />

Global Functions summary<br />

Modifiers Signature Description<br />

Array([numElements],<br />

[elementN]) : Array<br />

Boolean(expression:Obje<br />

ct) : Boolean<br />

Creates a new, empty array or converts specified<br />

elements to an array.<br />

Converts the parameter expression to a Boolean<br />

value <strong>and</strong> returns true or false.<br />

call(frame:Object) Deprecated since Flash Player 5. This action was<br />

deprecated in favor of the function statement.<br />

Executes the script in the called frame without<br />

moving the playhead to that frame.<br />

chr(number:Number) :<br />

String<br />

clearInterval(intervalI<br />

D:Number)<br />

Deprecated since Flash Player 5. This function was<br />

deprecated in favor of String.fromCharCode().<br />

Converts ASCII code numbers to characters.<br />

Cancels an interval created by a call to<br />

setInterval().<br />

Global Functions 31

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

Saved successfully!

Ooh no, something went wrong!