2.3.2 initErrorEvent

Initializes the properties of an ErrorEvent object.

As of Microsoft Edge, the createEvent / initEvent constructor pattern for synthetic events has been deprecated in favor of the DOM4 event constructor pattern.

Available only in IE10, IE11, and EdgeHTML Mode (All Versions).

The initErrorEvent method extends the ErrorEvent interface.


DOMString typeArg The type of event being created

boolean canBubbleArg Indicates whether the event can bubble

boolean cancelableArg Indicates whether the default action of the event can be prevented

DOMString messageArg The error message string

DOMString filenameArg The absolute URL of the script in which the error originally occurred

Unsigned long linenoArg The line number where the error occurred in the script

Return Value