flash: why use "var"?
flash: why use "var"?
Out of context: Reply #5
- Started
- Last post
- 13 Responses
- ave0
...the scope (life) of a variable is determined by the position of that variable within the movie. A variable contained within a function lasts for the duration of that function (local scope), a variable located outside of any functions takes on the scope of its parent timeline.
Using "var" has no bearing on the life of a variable. It's coding edicate with actionscript - and let's not forget to comment our code!