2 Replies Latest reply on Dec 18, 2006 11:51 AM by ntsiii

    Is there a way to import using MXML?

    Graeme Harker Level 1
      This works but is kinda clumsy. It would be more elegant if there was a way of doing an "import" using MXML (e.g. mx:Component import="mx.controls.Alert" or something like that). Is there a way to do an "import" without having to resort to mx:Script?

      <mx:itemRenderer>
      ___<mx:Component>
      ______<mx:Button label="Sell" click="Alert.show('Do you want to procede?' , 'Sell Trade' , Alert.OK | Alert.CANCEL )" >
      _________<mx:Script>
      ____________<![CDATA[
      _______________import mx.controls.Alert ;
      ____________]]>
      _________</mx:Script>
      ______</mx:Button>
      ___</mx:Component>
      </mx:itemRenderer>