开发者

How do I check if a swf file loaded correctly since put_Movie always returns S_OK?

开发者 https://www.devze.com 2022-12-17 23:14 出处:网络
I am using the latest flash player and have a swf file served locally from my dev machine.In one container test app I am able to play the swf and make calls to it, but in my \"Real\" application the s

I am using the latest flash player and have a swf file served locally from my dev machine. In one container test app I am able to play the swf and make calls to it, but in my "Real" application the same code path results in com errors (basically it looks like the swf isn;' loading properly)

Additionally this is made more challenging because no matter what nonsense I put in the call to put_Movie() the return is ALWAYS S_OK. This is confusing.

How am I supposed to determine if the swf file loaded and is working?

As a follow-on, what would cause a swf file (th开发者_JS百科e same one) not to load in a different app? The code paths are the same (from what I can tell).

Obviousl something is going on, but I am not sure what.

So, I guess 2 questions

  • How to know when swf file doesn't load right
  • Why might it fail in a different container application?

I am using ATL in Visual studio 2008, latest flash, MS Vista

Thanks


Hmm, it seems that if I listen for the DISPID_READYSTATECHANGE events then that helps me.

A value of '4' seems to indicate it is ready to accept method calls.

0

精彩评论

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