//Add this attribute to the toc element itemRollOver="setLastTreeItem(event)" //Add these import import mx.events.ListEvent; import com.esri.maplib.tocClasses.TocItem; //Add this var public var lastTreeItem:ListEvent; //Add this new function public function setLastTreeItem(event:ListEvent):void { lastTreeItem = event; } //Then you can add something like this to your function to get a TocItem var item:TocItem = TocItem(lastTreeItem.itemRenderer.data);
Signed in members can post, follow updates, and more. New here? Register a free account.
Find useful guides, FAQs, and documents to help you navigate and make the most of Esri Community.