2 Replies Latest reply on Jan 18, 2009 2:37 PM by gonzo2025

    Embedded SWF or image events problem

    gonzo2025
      Hi,

      when I try to load an embedded SWF with a SWFLoader control or an embedded image with an Image control, the complete, init, ... events don't fire. What could be the problem? A piece of code:

      <mx:SWFLoader id="loader" source="{testClass}" complete="Alert.show('test');"/>

      <mx:Script>
      <![CDATA[
      [Embed(source="test.swf")]
      [Bindable]
      public var testClass:Class;
      ]]>
      </mx:Script>

      Thank you very much.
        • 1. Re: Embedded SWF or image loading events problem
          Level 7

          "gonzo2025" <webforumsuser@macromedia.com> wrote in message
          news:gkvr2d$f4p$1@forums.macromedia.com...
          > Hi,
          >
          > when I try to load an embedded SWF with a SWFLoader control or an embedded
          > image with an Image control, the complete, init, ... events don't fire.
          > What
          > could be the problem? A piece of code:
          >
          > <mx:SWFLoader id="loader" source="{testClass}"
          > complete="Alert.show('test');"/>

          I think maybe you need to use an external swf if you're using swfLoader.


          • 2. Embedded SWF or image events problem
            gonzo2025 Level 1
            Thank you for your response.

            If I use a external SWF it works, but I want to embed and control it like you do using SWFLoader, because controlling the timeline of an embedded SWF is a bit dirty:

            Loader(DisplayObjectContainer(new testClass()).getChildAt(0)).content;

            Thanks again.