Hi there I have an ArrayCollection value in my model class, which I would like to run through a formatter function in my view. This method works with a string, but performs strangely for a collection, where: 1) The format function is never called on update 2) The bound control reflects the update if I return the ArrayCollection reference from the function, and doesn't reflect the update if I return a reference to a different object (even though the function is never called)
View: -------------------- snip --------------------------- // formatting function public function formatTree(data:ArrayCollection) { data.addItem(new MoveVO()); return data; } -------------------- /snip --------------------------- -------------------- snip --------------------------- // tree control <mx:Tree id="moveTree" x="203" y="2" dataProvider="{formatTree(model.currentMoves)}" labelField="text" height="190" width="193"></mx:Tree> -------------------- /snip --------------------------- I have also tried using a <mx:Binding> tag to perform the operation, as well as Paul Williams 'smallest tag'*, both of which do not reflect an update to the ArrayCollection value. Trying to follow up on this in the documentation I found the following, which seems to imply that the formatting function should work: "You can use ActionScript functions as the source of binding expressions. You usually do this when using a bindable property as an argument of a function. When the bindable property changes, the function executes, and the result is used in the binding destination ..." Regards Tracy *http://weblogs.macromedia.com/paulw/archives/2006/05/the_worlds_smal.cfm -- Flexcoders Mailing List FAQ: http://groups.yahoo.com/group/flexcoders/files/flexcodersFAQ.txt Search Archives: http://www.mail-archive.com/flexcoders%40yahoogroups.com Yahoo! Groups Links <*> To visit your group on the web, go to: http://groups.yahoo.com/group/flexcoders/ <*> To unsubscribe from this group, send an email to: [EMAIL PROTECTED] <*> Your use of Yahoo! Groups is subject to: http://docs.yahoo.com/info/terms/