topical media & game development

talk show tell print [swf] flex

  <?xml version="1.0" encoding="utf-8"?>
  <mx:Application xmlns:mx="" layout="absolute" creationComplete="init()" backgroundGradientColors="[#ffffff, #ffffff]" width="400" height="200">
                          import flx.external.FlashInterface;
                          import mx.controls.Alert;
                          private var flaface:FlashInterface;
                          private var count:Number = 1;
                          public var logo:Class;
                          private function init():void
                                  FlashInterface.addEventListener("talkToFlash", talkToFlashHandler);
                          private function talkToFlashHandler(evt:FlashInterfaceEvent):void
                                  txtOutput.htmlText = "<p>" + + "</p>";
                          private function clearOutput():void
                                  txtOutput.text = "";
          <mx:Canvas cornerRadius="8" borderStyle="solid" left="5" top="5" bottom="5" right="5">
                  <mx:Image x="330" y="10" width="48" height="48" source="{logo}" scaleContent="false"/>
                  <mx:Label x="14" y="6" text="Flash 9 - Subscriber" fontWeight="bold" fontStyle="italic" fontSize="16" fontFamily="Arial" color="#cc0000"/>
                  <mx:Label x="14" y="33" text="FlashInterface.addEventListener" fontWeight="bold" fontSize="12"/>
                  <mx:Text x="14" y="61" fontSize="11" text="Type message to send to subscriber."/>
                  <mx:Button label="Clear" click="clearOutput()" right="10" bottom="10"/>
                  <mx:TextArea x="10" y="82" width="368" height="66" id="txtOutput"/>

(C) Æliens 27/08/2009

You may not copy or print any of this material without explicit permission of the author or the publisher. In case of other copyright issues, contact the author.