When I was using ExternalInterface earlier this year, I noticed that you
can't access any exposed method until the swift has finished loading.

Sean McArthur
On Dec 2, 2010 8:38 AM, "stratboy" <[email protected]> wrote:
> Some of my code:
>
> AS
> stop();
> import flash.external.ExternalInterface
>
> function js_callable(){
> test_txt.text = 'ok';
> }
>
> ExternalInterface.addCallback('swf_action',js_callable);
>
>
> JS
>
> window.addEvent('domready',function(){
>
> var swfobj = new Swiff('files/swf/italy.swf',{
> id:'italy',
> container:'italy-flash',
> width:280,
> height:323,
> params:{
> bgcolor:'#ffffff',
> wmode:'opaque',
> allowScriptAccess:'always'
> }
> });
>
> Swiff.remote(swfobj,'swf_action'); //__flash__argumentsToXML is not
> defined
>
> console.log($('italy')); //ok
> $('italy').swf_action(); //$("italy").swf_action is not a function
>
> });
>

Reply via email to