0 Replies Latest reply on Aug 30, 2007 11:37 AM by Rajesh.Gowdety's

    icons in menu

    Rajesh.Gowdety's
      Hi,
      I am not getting the icons in the menu. I have the following code in my application,
      [Bindable]
      [Embed(source='/img/page_go.png')]
      public var Prescription:Class;

      [Bindable]
      [Embed(source='/img/page_edit.png')]
      public var PatientEdit:Class;

      [Bindable]
      public var menuCollection:XMLListCollection;
      [Bindable]
      public var menuCollection:XMLListCollection;

      private var menuXML:XMLList = <>

      <menuitem label="See Patient Chart" icon="PatientChart" />
      <menuitem label="Edit Patient" icon="Prescription" />
      <menuitem label="Create Prescription" icon="PatientEdit" />

      </>
      private function initMenuCollections():void {
      menuCollection = new XMLListCollection(menuXML);
      }

      actionMenu = Menu.createMenu(null, menuCollection, false);
      actionMenu.labelField="@label";
      actionMenu.iconField = "@icon";
      actionMenu.menuSelectionMode = true;
      actionMenu.show(event.stageX,event.stageY);
      actionMenu.addEventListener(MouseEvent.ROLL_OVER,rollOverHandler);
      actionMenu.addEventListener(MouseEvent.ROLL_OUT,rollOutEffect);
      actionMenu.addEventListener(MenuEvent.ITEM_CLICK,menuHandler);
      what is the problem?,

      Thanks in advance,