Partager via


External.OnChangeViewError Event

[The feature associated with this page, Windows Media Player SDK, is a legacy feature. It has been superseded by MediaPlayer. MediaPlayer has been optimized for Windows 10 and Windows 11. Microsoft strongly recommends that new code use MediaPlayer instead of Windows Media Player SDK, when possible. Microsoft suggests that existing code that uses the legacy APIs be rewritten to use the new APIs if possible.]

Note

This topic describes functionality designed for use by online stores. Use of this functionality outside the context of an online store is not supported.

The OnChangeViewError event occurs when a call to the External.changeView method results in an error.

window.external.OnChangeViewError = FunctionName

Possible Values

This is a write-only property that specifies the name of the function in script that Windows Media Player calls when the event occurs.

Parameters

The function that handles this event has the following parameters.

hr

An HRESULT failure code that indicates the reason for the failure.

LibraryLocationType

The same string that was passed in the LibraryLocationType parameter of changeView.

LibraryLocationID

The same string thatwas passed in the LibraryLocationID parameter of changeView.

Filter

The same string that was passed in the Filter parameter of changeView.

ViewParams

The same string that was passed in the ViewParams parameter of changeView.

Requirements

Requirement Value
Version
Windows Media Player 11
DLL
Wmp.dll

See also

ExternalObject for Type 1 Online Stores