开发者

Loading a swf named in xml into a parent swf in Actionscript 3

开发者 https://www.devze.com 2023-01-12 12:55 出处:网络
OK, I have a situation where I use loadvars to load an xml file, which has the address of 2 swf\'s on the server.I can trace the xml items so know they are loading.So I\'m trying to load the swf\'s bu

OK, I have a situation where I use loadvars to load an xml file, which has the address of 2 swf's on the server. I can trace the xml items so know they are loading. So I'm trying to load the swf's but am running into problems. First problem, the swf always gives an error when I publish from flash, "TypeError: Error #2007: Parameter url must be non-null." as it can't find the mention of the xml file, as it's just being published. I'm not sure this affects the next issue which is the swf not loading when I try to load it like this:

开发者_开发技巧var loader:Loader = new Loader();
var defaultSWF:URLRequest = new URLRequest(loadswf1); // where I know loadswf1 = "myswf.swf"
loader.load(defaultSWF);

any advice appreciated, Thanks


Sorry if I'm stating the obvious but there's very little code to go by... Are you starting to load your SWFs after the XML loading has completed?

0

精彩评论

暂无评论...
验证码 换一张
取 消