OnSourceDownloadComplete (Silverlight Plug-in Object)


Gets or sets the name of the event handler that is called when the source download has finished.

object Element

<object ...>
  <param name="onsourcedownloadcomplete" value="functionname"/>


Not implemented in the functions.


Do not use; use the object parameter as the handler attachment point.



Managed Code

Not available.

The name of the function that is invoked when the source download has finished. The default value is null.

The event reports download completion for the package that has been requested through the Source property.

The most typical scenario for noting download completion is to display a message in an area of the hosting HTML page (not in the splash screen). The splash-screen XAML page has reached the end of its lifetime when the event occurs. Therefore, it does not make sense to report download completion in the splash screen.

Any JavaScript code for the splash screen (including event handlers that are referenced by this property) must be made in a script block or in an included script file that is referenced from the hosting HTML page.

If you are referencing a Source that is cross-domain from the hosting HTML, handlers for OnSourceDownloadComplete or OnSourceDownloadProgressChanged are never invoked. Therefore you can only display indeterminate splash screens if loading source cross-domain. The hosting HTML may wish to assign a handler for OnLoad in this case, as it is the best available object lifetime event for resetting state after the source XAP loads.

For more information about how to work with splash screens, see Silverlight Splash Screens.

Arguments for an OnSourceDownloadCompleted Function



The Silverlight plug-in that raised the event.


Always null.

Community Additions