Also note that Arrays in Flex are not typed (there's no concept of String[]or 
Number[]) so you can store any kind of data into an Array and mix it, too:

var arr:Array = new Array();
arr.push(123);
arr.push("foo");
arr.push(new Date());

Dirk.


> -----Original Message-----
> From: Manish Jethani [mailto:[EMAIL PROTECTED]
> Sent: Monday, February 14, 2005 7:20 AM
> To: [email protected]
> Subject: Re: [flexcoders] Question about arrays
> 
> 
> 
> [EMAIL PROTECTED] wrote:
> > Is making arrays with Flex similar to making arrays with 
> Visual basic 
> > meaning is it possible to make an array of objects like say 
> an array of 
> > buttons or labels?
> 
> Yes.
> 
> var buttons:Array = new Array(10); // 10 buttons
> for (var i:Number = 0; i < buttons.length; i++)
> buttons[i] = container.createChild(Button, "", {label: "Test"});
> 
> (Strictly speaking, you make arrays of _references_ to objects, not 
> arrays of objects themselves.)
> 
> Manish
> 
> 
>  
> Yahoo! Groups Links
> 
> 
> 
>  
> 
> 
> 
> 


Reply via email to