1 Reply Latest reply on Jan 14, 2011 10:08 AM by Flex harUI

    loadForCompatibility in FP 10 vs. 10.1 and bootstrap vs. sandbox




      I know there is a lot of content related to this on the forum but I couldn't find answer to my questions...


      I use bootstrap loader for my application. It was introduced to get rid of issues like :


      TypeError: Error #1034: Type Coercion failed: cannot convert Object@eda8ba1 to mx.messaging.messages.ErrorMessage.


      I also use loadForCompatibility=true in SWFLoader. This configuration was working fine for some time. However recent changes in application made this configuration not working any more.


      Here comes my 2 questions:

      1. I noticed that in Flash Player 10.1 bootstrap loader is no longer required(It is required in version 10, however). I don't experience any issues related to RPC or class definitions conflicts. Do I understand it right that version 10.1 introduced fixes  to the way flash is loading classes and I can expect it will work the same way in future versions?
      2. According to this document  An alternative to bootstrap loader is using sandboxed applications. However it doesn't say how to do this, how to load a sub application into different security domain. Sub application which is local to the parent application (is on the same web server )

                parent application : http://domain.com/Main.swf

                sub application     : http//domain.com/sub/SubApplication.swf.


              I want to load SubApplication from Main as a sandboxed application. I already experienced with trustContent and LoaderContext but they don't seem to work as I expect it to work. That is I cannot do something like context.securityDomain = new SecurityDomain(). Since both applications are on the same web domain by default they are loaded to same security domain.


      thanks for the answers.