actionscript 3 - Load AS2 SWF Into AS3 SWF and pass vars in URL -


I have got an AS3 SWF that I am loading other SWFs. These children SWF take a parameter on all the URLs. While loading the AS2 child I can not get to do this work, and it should be able to handle both of them.

So I have

  var request: URLRequest = new URLRequest (); Var loader: URL loader = new URL loader (); Request.url = "http: //domain/as2.swf? Param = foo"; Loader.load (request); // etc. for Eventelists, Edible, etc. When the AS2 SWF loads, it can not see the parameter I have passed. It's looking for _root.param, am I doing this wrong or am I trying to do the impossible? 

Edit: I should add that I can load an SWF with those URL parameters from the AS2 loader and it works just fine.

Div>

They are not trivial to communicate between AS2 and AS3 because they run in various virtual machines. Check it for some signals.

EDIT: If you can not change the loaded as2 content, then your only option is creating the 'cover' as2 loader which uses the above linked example, which is as3 and the interface Loaded As2 content is not very good by using _root.varname but it can only work.


Comments