1.4 Variables

Variables define properties whose values can change at runtime. They can be defined with either the var keyword or the const keyword. A variable that is defined with the var keyword may be assigned by any code that can access it. A variable that is defined with the const keyword may only be set by its initializer, or its class's instance constructor if it is an instance variable. An example of variables follows:

var x = 10
const PI = 3.1415

 

Send me an e-mail when comments are added to this page | Comment Report

Current page: http://livedocs.adobe.com/specs/actionscript/3/as3_specification6.html