[flashvideo file=video/ASCreatingNumberVariables.flv /]We create and assign values to a variable twice, the classic and condensed way.
Here is the code:
//Assignment Operators
var myValue:Number =2;
myValue = myValue +2;
trace (myValue);
// Condensed Code
var myOtherValue:Number = 2;
myOtherValue += 2;
trace (myOtherValue);
DOWNLOAD THE SOURCE FILES






Thu, Jul 30, 2009
ActionScript