Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

DownloadProgressChanged (MediaElement)

Silverlight

Occurs when the DownloadProgress (MediaElement) property has changed.

<object DownloadProgressChanged="eventhandlerFunction"  .../>
[token = ]object.AddEventListener("DownloadProgressChanged", eventhandlerFunction)

AddEventListener Parameters

token

integer

A token that is returned from the function, which you can optionally retain as a variable. If you intend to call RemoveEventListener to remove the handler, you will need this token.

eventhandlerFunction

object

The name of your event handler function as it is defined in script. When used as an AddEventListener parameter, quotation marks around the function name are not required. (See the "Remarks" section.)

Event Handler Parameters

sender

object

The object that invoked the event.

eventArgs

object

This parameter is always set to null.

You can also add handlers in script by using a quoted string for the event handler name, as follows:

object.AddEventListener("DownloadProgressChanged", "eventhandlerFunction")

This syntax also returns a token. However, the token is not an absolute requirement for removing the handler in cases where the handler was added by using a quoted string. For details, see RemoveEventListener.

The DownloadProgressChanged event occurs for progressive downloads, typically occuring more than once. This event occurs whenever the amount of total content downloaded increases by 0.05 or more (as a factor of 1.0, which indicates completion), or reaches 1.0.

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

ADD
Show:
© 2014 Microsoft. All rights reserved.