Error.clearErrorQueue method
The clearErrorQueue method clears the errors from the error queue.
Syntax
Error.clearErrorQueue()
Parameters
This method has no parameters.
Return value
This method does not return a value.
Remarks
This method is useful to clear the error queue after a series of errors has been processed.
You should set Settings.enableErrorDialogs to false if you choose to display custom error messages.
Examples
The following JScript example uses Error.clearErrorQueue in an event handler to empty the error queue after all error descriptions are displayed. The Player object was created with ID = "Player".
<SCRIPT LANGUAGE = "JScript" FOR = Player EVENT = error()>
// Store the number of errors in the queue.
var max = Player.error.errorCount
// Loop through the list of errors.
for (var i = 0; i < max; i++){
// Get the error description for this item.
var errDesc = Player.error.item(i).errorDescription;
// Display the error message.
alert(errDesc);
}
// Clear the error queue to prepare for the next group of errors.
Player.error.clearErrorQueue();
</SCRIPT>
Requirements
Version |
Windows Media Player version 7.0 or later. |
DLL |
|