Thanks for pointing me in the right direction Alex! But how do you access the specific menu item from there on? I can't figure out how the menu item in the XML is reached by the isToggled or setToggled method. Would be great if you can give me a small example.
Sascha From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Alex Harui Sent: Sunday, April 01, 2007 02:53 To: [email protected] Subject: RE: [flexcoders] Toggling Menu Item? The dataDescriptor has an isToggled method that is passed the data item and returns true or false. By default, it looks for a toggled="true" _____ From: [email protected] [mailto:[EMAIL PROTECTED] On Behalf Of Sascha Sent: Friday, March 30, 2007 11:48 PM To: [email protected] Subject: [flexcoders] Toggling Menu Item? Hi list, Since I cannot find any information about this anywhere else . How do you toggle a (flex 2 ) check/radio menu item from ActionScript? Say I use an XML object to populate my MenuBar with . private var _menuXML:XMLList = <> <menuitem label="Foo"> <menuitem label="Bar" type="check" data="bar"/> </menuitem> </>; var _menubar:MenuBar = new MenuBar(); _menubar.dataProvider = _menuXML; . how are you able to toggle the check item on/off with ActionScript? I don't see any way to reach the specific item via MenuBar properties. Thanks in advance for any tips! Sascha

