Add submenu to submenu
<?xml version="1.0"?> <mx:Application xmlns:mx="http://www.adobe.com/2006/mxml" backgroundColor="#FFFFFF"> <mx:XMLListCollection id="myMenuData"> <mx:XMLList> <menuitem label="File"> <submenu label="New" enabled="false" /> <submenu label="" type="separator" /> <submenu label="Open" icon="openIcon"> <submenu label="Doc" type="radio" groupName="openGroup" /> <submenu label="Pdf" type="radio" groupName="openGroup" toggled="true" /> </submenu> <submenu label="Auto Update" type="check" toggled="true" /> </menuitem> </mx:XMLList> </mx:XMLListCollection> <mx:Script> [Bindable] [Embed(source="logo.jpg")] public var openIcon:Class; import mx.controls.Menu; private function showMenu():void { var myMenu:Menu = Menu.createMenu(myButton, myMenuData); myMenu.labelField="@label"; myMenu.iconField="@icon"; myMenu.show(); } </mx:Script> <mx:Button id="myButton" label="Display Menu" click="showMenu()" /> </mx:Application>