2 Replies Latest reply on Mar 5, 2009 2:23 PM by otisme

    Loading Text

    otisme
      I get the error warning message below in from Flexbuilder project .mxml file running in debugger.

      Application runs but text is not loading in the panel inside a canvas that I've setup for it? It must be some data binding problem.

      I thought it might be a security sandbox issue but permissions on the folders have been granted to the
      flash player. Any solution to this binding xml issue appreciated.

      Also I get *** Security Sandbox Violation *** result of 2 image files not loading though they exist in the folder referenced and can be seen loaded in design view.

      here's one error message:

      warning: unable to bind to property 'label' on class 'XML' (class is not an IEventDispatcher)

      here's some of the code:(

      <![CDATA[

      import mx.controls.Image;
      import mx.events.ListEvent;
      import mx.events.ItemClickEvent;

      private var currentNavBar:String;
      private var currentNavButton:String;

      private var textLoader:URLLoader;

      private function init():void
      {
      aboutTextArea.htmlText = "<b>myTst</b><br />meTst";
      textLoader = new URLLoader();
      textLoader.load(new URLRequest("news.html"));
      textLoader.addEventListener(Event.COMPLETE, handleNewsHTML);
      }


      ]]>
      </mx:Script>

      rgds

      Colm
        • 1. Re: Loading Text
          robbyk87
          One reason why my html text wasnt showing up when I retrieved it from mySQL was because of the slashes. But I used php to get my xml so I used the stripslashes php command. I dont know if this applies in your case though.
          • 2. Re: Loading Text
            otisme Level 1
            Thanks,

            I'd left out the creationComplete="init()" declaration in the Application declaration, see below, a trace statement within the relevant init() function (see original code) showed me it wasn't running, but it took me a good while to figure out why:-( I finally got it:

            <mx:Application xmlns:mx=" http://www.adobe.com/2006/mxml" layout="absolute" creationComplete="init()" borderColor="#0C3F63" >

            I won't forget it again!

            Colm