|
Hmm, I tried that too, but with
arrMdta.addItem() it hangs my browser. Seem I can’t add objects to an
arraycollection, only arrays (and I don’t want to create an array for
each item in it) Thanks though From:
[email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Clint Tredway set this, arrMdta,
to a type of ArrayCollection not just an array.. On 8/3/06, Jonas
Windey <[EMAIL PROTECTED] Hmm, nope. This is what I
tried import mx.collections. [Bindable] public var arrMdta:Array
= new Array(); private function
init():void {
for(var i:Number = 1; i < 100; i++)
{
var filePath:String = "assets/image";
if(i.toString(
if(i.toString(
filePath += i.toString() + ".jpg";
arrMdta.push(
} } And in mxml <mx:ArrayCollection id="acGallery"
source="{arrMdta}" /> Repeater: <mx:Repeater
id="rptGallery" dataProvider="{acGallery}"> <ui:thumb
imagePath="{rptGallery. </mx:Repeater> No luck, now I don't have
any items. From:
[EMAIL PROTECTED]ups.com
[mailto: flexcoders@yahoogroups. Close... that's the point
of binding to an ArrayCollection. Shan From:
[EMAIL PROTECTED]ups.com
[mailto: flexcoders@yahoogroups. Hi, I have a repeater with a thumbnail in it. Code: <mx:Repeater id="rptGallery"
dataProvider="{arrMdta}"> <ui:thumb imagePath="{Mdta(rptGallery. </mx:Repeater>
In my script I have [Bindable] public var arrMdta:Array = [new
Mdta("assets/image001. So far so good, I see my image (inside my thumb
component there's an mx:image, nothing fancy Now the harder part, I try to bind the repeater to
the array (as I'm doing here, but when I change my array, it doesn't get
updated automatically. In my applicationComplete private function init():void { for(var i:Number = 1; i < 100; i++)
{ var filePath:String = "assets/image";
if(i.toString(
if(i.toString(
filePath += i.toString() + ".jpg";
arrMdta.push( } } This doesn't work, only when I put the following
line: rptGallery.dataProv Why is it only working if I re-force the dataProvider?
I thought that was the point of binding my data? Thanks for any help, Jonas
-- --
-- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com
SPONSORED LINKS
YAHOO! GROUPS LINKS
__,_._,___ |
- RE: [Junk E-Mail - MED] [flexcoders] Binding array to repe... Jonas Windey
- Re: [Junk E-Mail - MED] [flexcoders] Binding array to... Clint Tredway
- RE: [Junk E-Mail - MED] [flexcoders] Binding arra... Jonas Windey
- Re: [Junk E-Mail - MED] [flexcoders] Binding array to... Renaun Erickson

