2 Replies Latest reply on May 31, 2007 6:03 AM by EWyher

    Flex 2 and Flashpaper in a SWFLoader

    EWyher
      I'm hoping someone can help me figure out how to use a SWFLoader within an application to switch between displaying different flashpaper documents.

      Here is the mxml code that works as long as the source never changes:
      <mx:SWFLoader id="loaderStatement" source="cf_reports/statement.cfm?report_type=B"/>

      This is the actionscript code that I have tried to load a different document:

      var strMainURL:String="cf_reports/statement.cfm?report_type=C";
      loaderStatement.load(strMainURL);

      This actionscript code works to some extent: it finds the correct flashpaper document and loads it. The problem is that it kills the flashpaper functionality such as searching and printing. I assume that this is because Flashpaper is written in actionscript 2?

      Anyway, if there is a way to get around this, I would really appreciate it. Thank you very much!
        • 1. Re: Flex 2 and Flashpaper in a SWFLoader
          notacrook
          I am currently having this problem too. I'm loading the flashpaper documents in as images (not using the SWFloader).

          Only one flashpaper document will have full functionality. The rest will not zoom, print, etc...

          It seems to be that the first flashpaper I add works, and any subsequent ones do not (even if they occur earlier in the code)

          Any flashpaper guru's out there know about a simple setting we're missing here?

          Thanks!
          • 2. Re: Flex 2 and Flashpaper in a SWFLoader
            EWyher Level 1
            Notacrook, the answer I've gotten from Adobe is that they don't plan to release a new version of Flashpaper. Flashpaper is written in Actionscript 2.0, so it's not compatible with Flex 2.0 (which uses Actionscript 3.0). The specific problem you mention is the same exact one I was seeing when I was trying to force Flashpaper to work in Flex 2.0.

            I rewrote the application in Flex 1.5 (which I could do since my company purchased the server), and use the Loader to view multiple Flashpaper SWF's. It works beautifully. But of course, it is an older and more expensive technology, which isn't so cool.