In my application I read a XML file containing binary data representing a SWF file. I'm able then to display that SWF using a SWFLoader component and setting its 'source' property to the ByteArray I got from the XML file.
It's working nice but now I need to pass some parameters to the loaded SWF...How can I do that?
The code to load the SWF is as follows:
var loaderContext:LoaderContext = new LoaderContext();
loaderContext.allowLoadBytesCodeExecution = true;
var loader:SWFLoader = new SWFLoader();
loader.loaderContext = loaderContext;
loader.width = 300;
loader.height = 300;
loader.source = bytes; // bytes is the ByteArray
this.addElement(loader);