开发者

Throwing an error in ActionScript and catching it with JavaScript

I am using th开发者_如何学Ce ExternalInterface to communicate between Flash and JavaScript using callbacks and the call method. I would like to throw an exception in ActionScript 3.0 and catch it in JavaScript and I was please wondering if there was anyway to do that?

Thank you very much, Rudy


Should be something like:

try {
     // statements
} catch (error:Error) {
     ExternalInterface.call(functionsName, error.message);
}

Where functionsName is the function that will get the error as a parameter.

0

上一篇:

下一篇:

精彩评论

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

最新问答

问答排行榜