There is a quirk in Flash Player where the first swf it runs dictates the relative paths of all other swfs that are loaded. SWFLoader works around that, but in local mode you have make sure your trust files encompass the places it is loading from.
Most folks replace flashvars with url params. ________________________________ From: flexcoders@yahoogroups.com [mailto:[EMAIL PROTECTED] On Behalf Of reflexactions Sent: Saturday, November 03, 2007 8:11 PM To: flexcoders@yahoogroups.com Subject: [flexcoders] Loading a legacy swf - SecurityDomain issue I have a legacy AS2 swf, it usually runs in a web page and it is passed a couple of params via flashvars and then loads a few things like jpg/swf as children of _root etc. I am trying to see if its possible to have it loaded into a flex/air app. In this "root" would mean root of the loading swf not root of my flex app. I am using a loader component and it is clearly loading the swf but it dies when the legacy swf tries to load anything else. SecurityDomain 'file:///C:\AS2\v8.swf' tried to access incompatible context 'app-resource:/test.swf' file:///splash.jpg <file:///\\splash.jpg> All the legacy app was doing was: splash=_root.createEmptyMovieClip("splash",1); splash.createEmptyMovieClip("logo",1) splash.logo.loadMovie("splash.jpg"); This was specifically from an AIR application I was testing but the problem and solution are really flex related I think so I guess it is relevant to ask here If I can get passed this issue I still have the problem of how to pass in the flashvars in a way that works for both a web run swf and one loaded into flex/air, my thoughts were to switch to passing them on the url but not sure if there is a better way. Any solutions? tks