Icaro
Icaro

Reputation: 2787

How to Intercept last Opened/expanded node of a Flex Tree

I have a partially populated Tree component and I have to invoke a remote service when User expand (not when he select) a node to retrieve it's leafs. How I know witch node have bee selected.

I'm using Flex 3.3.

Upvotes: 0

Views: 362

Answers (1)

Icaro
Icaro

Reputation: 2787

I have resolved this way:

//The Gui

<mx:Tree id="tree" itemOpening="retriveLeafs(event)"/>

// The logic

   public function retriveLeafs(event:TreeEvent):void {
       var vo:MyCustomVO = event.item as MyCustomVO;
       //...
   }

Upvotes: 3

Related Questions