ApplicationControlBar and MenuBar
<?xml version="1.0"?>
<mx:Application xmlns:mx="http://www.adobe.com/2006/mxml">
<mx:XMLList id="menuXML">
<menuitem label="File">
<menuitem label="New" data="New" />
<menuitem label="Open" data="Open" />
<menuitem label="Save" data="Save" />
<menuitem label="Save As" data="Save As" />
<menuitem label="Exit" data="Exit" />
</menuitem>
<menuitem label="Edit">
<menuitem label="Cut" data="Cut" />
<menuitem label="Copy" data="Copy" />
<menuitem label="Paste" data="Paste" />
</menuitem>
<menuitem label="View" />
</mx:XMLList>
<mx:Array id="cmbDP">
<mx:String>Item 1</mx:String>
<mx:String>Item 2</mx:String>
<mx:String>Item 3</mx:String>
</mx:Array>
<mx:ApplicationControlBar id="dockedBar" dock="true">
<mx:MenuBar height="100%" dataProvider="{menuXML}" labelField="@label" showRoot="true" />
<mx:HBox paddingBottom="5" paddingTop="5">
<mx:ComboBox dataProvider="{cmbDP}" />
<mx:Spacer width="100%" />
<mx:TextInput id="myTI" text="" />
<mx:Button id="srch1" label="Search" click="mx.controls.Alert.show('Searching')" />
</mx:HBox>
</mx:ApplicationControlBar>
</mx:Application>
Related examples in the same category