I have created a Class that extends Array, called ArrayExtension. The only way
that I have found to add
values to this is array is in the following manner:
---
// CODE
import com.ArrayExtension
var myArray:ArrayExtension = new ArrayExtension(Hello,GoodBye,World)
//CLASS
Hi there (whoever you are!)
Your problem is that the [1,2,3] initialiser syntax is actually a
short cut for creating a new Array() object, not an ArrayExtension().
So you're replacing the object you just created with new().
What you need to do is to _modify_ your ArrayExtension() object, not
That will work...thanks.
Robert Leisle wrote;
You could also do:
var myArray:ArrayExtension = new ArrayExtension();
myArray.push(Hello, Goodbye, World);
same result as doing them separately.
___
Flashcoders@chattyfig.figleaf.com
To change your
3 matches
Mail list logo