0 Replies Latest reply on Oct 14, 2010 5:54 PM by Hottwiggz

    video (.flv embedded in a .swf) not working in Flex?

    Hottwiggz

      I am new to Flex, and I'm using version 3.5.  I have a .swf file with an embedded .flv in it, it works fine when exported in Flash but when I try to use it in my desktop Flex application I get errors.  What i'm trying to do is have the .swf popup and play the video.  Any help will be deeply appreciated.

       

      Here is my code, I know there is something missing but can't tell what........be gentle.

       

       

      <?xml version="1.0" encoding="utf-8"?>

      <mx:Canvas xmlns:mx="http://www.adobe.com/2006/mxml" width="308" height="400"  horizontalCenter="0" creationComplete="init()">

      <mx:Script>

      <![CDATA[

      import mx.managers.PopUpManager;

       

      private function init():void

      {

      stage.addEventListener(MouseEvent.MOUSE_DOWN, closeInstructions, false, 0, true);

      }

       

      private function closeInstructions(event:MouseEvent):void

      {

      stage.removeEventListener(MouseEvent.MOUSE_DOWN, closeInstructions, false);

      PopUpManager.removePopUp(this);

      }

      ]]>

      </mx:Script>

      <mx:Image id="FLVPlayer" source="@Embed('assets/customFLVPlayer.swf')" horizontalCenter="0"/>

      </mx:Canvas>