Freigeben über


initProgressEvent method

Initializes the value of a ProgressEvent object.

 

Syntax

HRESULT retVal = object.initProgressEvent(typeArg, canBubbleArg, cancelableArg, lengthComputable, loadedArg, totalArg);

Parameters

  • typeArg [in]
    Type: DOMString

    The value of this parameter must be one of the following values.

    Value Meaning
    loadstart

    An operation has started.

    progress

    An operation is in progress.

    error

    The operation failed to complete.

    abort

    The operation was cancelled.

    load

    The operation completed successfully.

     

  • canBubbleArg [in]
    Type: boolean

    Specifies whether an event bubbles.

    Value Meaning
    true

    The event bubbles.

    false

    The event does not bubble.

     

  • cancelableArg [in]
    Type: boolean

    Specifies whether an event can be cancelled.

    Value Meaning
    true

    The event can be canceled.

    false

    The event cannot be canceled.

     

  • lengthComputable [in]
    Type: boolean

    Indicates whether the value of the IDOMProgressEvent::total attribute of the ProgressEvent is accurate.

    Value Meaning
    true

    The value of IDOMProgressEvent::total is reliable.

    false

    The value of IDOMProgressEvent::total is not reliable.

     

  • loadedArg [in]
    Type: integer

    Specifies the number of bytes already loaded or zero if not known.

  • totalArg [in]
    Type: integer

    Specifies the number of bytes to be loaded. If lengthComputable is false, this must be zero ("0").

Return value

Type: HRESULT

This method can return one of these values.

S_OK