Ref. below e.g.: Even if Array Collection is static, it should reflect the changes because it is Bindable.
MainApplication.mxml --------------------------------- <?xml version="1.0" encoding="utf-8"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" layout="absolute" > <mx:Script> <![CDATA[ *import* components.ModifyArrayCollection; *import* components.RepeaterDataProvider; ]]> </mx:Script> <mx:Repeater id="myRepeater" dataProvider="{ RepeaterDataProvider.myArrayCollection}" > <mx:Canvas width="50" height="50" x="{RepeaterDataProvider.xVal+=70}" y="100" backgroundColor="{myRepeater.currentItem.color}"/> </mx:Repeater> <mx:Button label="Add Item" click="ModifyArrayCollection.addItem()" x="100" /> <mx:Button label="Remove Item" click="ModifyArrayCollection.removeItem()" x="250"/> </mx:Application> ---------------------------------- Class containing Static and Bindable Array Collection -------------------------------------------- * package* components { *import* mx.collections.ArrayCollection; *public* *class* RepeaterDataProvider { [*Bindable*] *public* *static* *var* myArrayCollection:ArrayCollection = *new*ArrayCollection([{color: *"0xcccccc"*},{color:*"ox00ff00"*},{color:*"0xccff00"*}]);; *public* *static* *var* xVal:Number=50; *public* *function* RepeaterDataProvider() { } } } -------------------------------------------- Class modifying ArrayCollection ----------------------------------------------- * package* components { *public* *class* ModifyArrayCollection { *public* *function* ModifyArrayCollection() { } *public* *static* *function* addItem():*void * { *var* obj:Object = *new* Object(); obj.color = *"0xffffff"*; RepeaterDataProvider.xVal=50; RepeaterDataProvider.myArrayCollection.addItem(obj); } *public* *static* *function* removeItem():*void * { RepeaterDataProvider.xVal=50; RepeaterDataProvider.myArrayCollection.removeItemAt(RepeaterDataProvider.myArrayCollection.length-1); } } } ---------------------------------------------- If you still find the same issue, Try Calling Repeater.*validateNow()*method. On Sat, Apr 3, 2010 at 3:50 PM, Shreyas <[email protected]> wrote: > Hi, > > I am using a Repeater whose data provider is an Array Collection > [static and bindable]. > > When I edit / delete the items of the Array Collection in another > component (the reason the AC is static), how can I refresh the > Repeater to show the modified values? > > -- > You received this message because you are subscribed to the Google Groups > "Flex India Community" group. > To post to this group, send email to [email protected]. > To unsubscribe from this group, send email to > [email protected]<flex_india%[email protected]> > . > For more options, visit this group at > http://groups.google.com/group/flex_india?hl=en. > > -- You received this message because you are subscribed to the Google Groups "Flex India Community" group. To post to this group, send email to [email protected]. To unsubscribe from this group, send email to [email protected]. For more options, visit this group at http://groups.google.com/group/flex_india?hl=en.

