I'll try the repeater. It takes a datasource, which I have a handle on. Thanks everyone!
--- In flexcoders@yahoogroups.com, Darrin Kay <dar...@...> wrote: > > I just built a carousel and had a lot of these issues, now the data for this > is comeing from an XML file, but that should not matter. You can not make a > panel backgroundImage dynamic, instead add a image to the panel like I did > below. > > > <mx:Repeater id="imageRepeater" dataProvider="{imageData.lastResult.panel}"> > > <mx:Panel id="MainPanel" xmlns:mx="http://www.adobe.com/2006/mxml" layout=" > absolute" fontFamily="gunPlayCSS" fontWeight="bold" > > title="{imageRepeater.currentItem.title}" width="450" height="253" > themeColor="#C4BA88" borderColor="#C4BA88" headerColors="#C4BA88" > > roundedBottomCorners="true" cornerRadius="15" horizontalScrollPolicy="off" > verticalScrollPolicy="off"> > > <mx:Image id="backgroundImage" source="{imageRepeater.currentItem.background > }" /> > > <mx:Text id="panelSub" x="109" y="24" width="316" height="33" htmlText="{ > imageRepeater.currentItem.sub}" fontFamily="gunPlayCSS" fontSize="20"/> > > <mx:TextArea id="panelBody" editable="false" alpha="0" x="109" y="56" > width="316" height="141" text="{imageRepeater.currentItem.body}" > fontFamily="gunPlayCSS" fontSize="15" textAlign="center" themeColor="#C4BA88 > "/> > > <mx:Text text="{imageRepeater.currentItem.linkText}" click="{navigateToURL(* > new* URLRequest(event.currentTarget.getRepeaterItem().link), *'_self'*);}" > x="109" y="195" fontFamily="gunPlayCSS" fontSize="14" height="22" color=" > #2034F6" width="216"/> > > </mx:Panel> > > </mx:Repeater> > > > On Mon, Feb 22, 2010 at 1:53 AM, flexnewbie999 > <wgb.jobsearch....@...>wrote: > > > > > > > I have a ArrayCollection of objects that contain an image and other fields. > > I need to dynamically created a panel for each image in succession as the > > collection is iterated over (at least that's the idea I've come up with). I > > can hard code each individual image via mxml into a panel but that doesn' > > suit my purposes as I never know how many items are in the collection. I've > > looked at itemRenderers but that doesn't seem to go since they only appear > > to work with grids and lists etc. I'm relatively new at this; is coding this > > type of thing the only solution to this problem or are there components I'm > > missing? > > > > Thanks! > > > > > > >