Partager via


item method

Retrieves a frame or iframe object from the collection.

 

Syntax

HRESULT retVal = object.item(pvarIndex, pvarResult);

Parameters

  • pvarIndex [in]
    Type: VARIANT

    An VARIANT of type VT_I4 that specifies the zero-based index, or a VARIANT of type VT_BSTR that specifies the name of the element to retrieve. If a VARIANT of type VT_EMPTY or VT_NULL is passed, the collection itself is returned.

  • pvarResult [out, retval]
    Type: VARIANT

    A VARIANT of type VT_DISPATCH that receives an IHTMLWindow2 interface for the object, if successful.

Return value

Type: HRESULT

If this method succeeds, it returns S_OK. Otherwise, it returns an HRESULT error code.