The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.
initCustomEvent method
Initializes a new custom event that the createEvent method created.
Important As of Microsoft Edge, the
createEvent()/initEvent() constructor pattern for synthetic events is deprecated. See the Synthetic Events page for more information.![]() ![]() |
Syntax
var retval = CustomEvent.initCustomEvent(eventType, canBubble, cancelable, detail);Parameters
- eventType [in]
-
Type: String
A user-defined custom event type.
- canBubble [in]
-
Type: Boolean
- cancelable [in]
-
Type: Boolean
- detail [in]
-
Type: Object
A user-defined object that can contain additional information about the event. This parameter can be null. This value is returned in the detail property of the event.
Return value
Type: HRESULT
If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.
Standards information
See also
Show:

