views:

13

answers:

1

I need a silverlight xap to notify the page somehow once it's finished loading. I was trying to use Javascript to call into the control via $(document).ready(...) but it looks like ActiveX controls can continue loading after the document ready event fires. Is there an event on the object tag I can have call a function?

A: 

you need to provide the Plugin with an onload param that contains the name of function to execute once the application has loaded.

Html:-

<object ....>
  <param name="onload" value="onsilverlightload" />
  ...
</object>

Javascript:-

function onsilverlightload(sender, eventargs)
{
   var pluginElem = sender.getHost();
   //Do stuff.
}
AnthonyWJones