Question
Newbie question: Completion Events for RemoteObject calls
I'm working on an application where I build a tree (in actionscript buildtree()) where I add new leafs from data that is retieve from a remote call.
Since the buildtree() function deals with the view - I have this coded in the view mxml. The tree is bound to a XMLListCollection which is updated by the buildtree() function.
The RetrieveDataCommand successfully retrieves the data into a business value object.
What is the correct Cairgorm method for triggering the builtree() function after the RetrieveDataCommand is complete?
I don't want to pollute my Command logic with any specific calls to buildtree()
Should I be adding RemoteCommandComplete events to all of my RemoteCommands? and then set the view logic to listen for them?
I tried to set a Collection.COLLECTION_CHANGE listener on the Business Value object from my View logic. But it seems to fire before the ArrayCollection is complete.
Any experts out there? I'm sure there must be a simple solution for this.
Since the buildtree() function deals with the view - I have this coded in the view mxml. The tree is bound to a XMLListCollection which is updated by the buildtree() function.
The RetrieveDataCommand successfully retrieves the data into a business value object.
What is the correct Cairgorm method for triggering the builtree() function after the RetrieveDataCommand is complete?
I don't want to pollute my Command logic with any specific calls to buildtree()
Should I be adding RemoteCommandComplete events to all of my RemoteCommands? and then set the view logic to listen for them?
I tried to set a Collection.COLLECTION_CHANGE listener on the Business Value object from my View logic. But it seems to fire before the ArrayCollection is complete.
Any experts out there? I'm sure there must be a simple solution for this.
