try mx.events.ItemClickEvent <mx:Script> <![CDATA[ import mx.events.ItemClickEvent;
public function getCompanyDetail(event:ItemClickEvent):void { // your code here... } ]]> </mx:Script> <mx:Tree id="tvCompanies" itemRenderer="CompanyTreeItemRenderer" itemClick="getCompanyDetail()" dataProvider="{myData.companies}" /> --- In flexcoders@yahoogroups.com, "jamiebadman" <[EMAIL PROTECTED]> wrote: > > Hi, > > Can someone help ? > > I've created a custom item renderer for a tree in which I have a > listener on the mouse click event. Unfortunately, though, the main > app code also needs to act on the click event - I have the tree > defined as: > > <mx:Tree id="tvCompanies" itemRenderer="CompanyTreeItemRenderer" > click="getCompanyDetail()" dataProvider="{myData.companies}" /> > > The event is being picked up by the renderer and the function in > there is working fine - but 'getCompanyDetail' isn't firing off at > all. > > Any ideas ? > > Thanks, > > Jamie. > -- 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/ <*> Your email settings: Individual Email | Traditional <*> To change settings online go to: http://groups.yahoo.com/group/flexcoders/join (Yahoo! ID required) <*> To change settings via email: mailto:[EMAIL PROTECTED] mailto:[EMAIL PROTECTED] <*> 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/