Actionscript 3 从链路[As3]加载外部Swf

Actionscript 3 从链路[As3]加载外部Swf,actionscript-3,Actionscript 3,我正在尝试从as3中的链接调用swf。我在网上搜索,我使用了这个代码 var my_Loader:Loader = new Loader(); var my_url:URLRequest=new URLRequest("http://gurselgunacar.web44.net/flash/yalitimhesabi.swf"); my_Loader.contentLoaderInfo.addEventListener(Event.COMPLETE, finishLoading); my_Lo

我正在尝试从as3中的链接调用swf。我在网上搜索,我使用了这个代码

var my_Loader:Loader = new Loader();
var my_url:URLRequest=new URLRequest("http://gurselgunacar.web44.net/flash/yalitimhesabi.swf");
my_Loader.contentLoaderInfo.addEventListener(Event.COMPLETE, finishLoading);
my_Loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, errorHandler);
my_Loader.load(my_url);
function finishLoading(loadEvent:Event) {
addChild(loadEvent.currentTarget.content);
}
function errorHandler(errorEvent:Event):void {
trace("file missing");
}
as3呼叫链接,但我无法在swf中执行任何操作。输出闪存中出现安全错误。我尝试了crossdomain.xml这个东西,但它不起作用:文件不存在。你应该创建一个。

加载程序将始终在目标服务器上查找crossdomain.xml文件。


哼哼。尝试添加以下安全功能:

Security.allowDomain("*");
Security.loadPolicyFile("http://gurselgunacar.web44.net/crossdomain.xml");
并在URL请求中使用:

var my_url:URLRequest=new URLRequest("http://gurselgunacar.web44.net/flash/yalitimhesabi.swf?" + new Date().getTime()); //this will avoid caching old swf.

我在EXE投影仪上进行了测试,它似乎可以工作。

我认为在flash环境中进行本地测试时,您不能像这样从internet请求文件。尝试将您的swf文件上载到您的网络主机。但我需要.exe格式:Sıupload,但仍然相同。安全问题已解决:)但现在在输出中:TypeError:Errorş1009:Boşnesne başvuruözelliğine veya yöntemine erişilemiyor。在佛罗里达州asdfg_::main timeline/frame1()我也不能用swf做任何事情。