This topic has not yet been rated - Rate this topic

getElementById method

Returns a reference to the first object with the specified ID value.

Internet Explorer 8

Syntax


var ppRetElement =
      document.getElementById(bstrId);
  

Parameters

bstrId [in]

Type: BSTR

A BSTR that specifies the ID, which is case sensitive.

ppRetElement [out, retval]

Type: IHTMLElement2

The address of a pointer to a variable of type IHTMLElement2 that receives the first object with the ID specified in bstrId.

Return value

Type: HRESULT

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

Remarks

This version of IHTMLDocument6::getElementById requires IE8 Standards mode compatibility. For more information, see Defining Document Compatibility

See also

document
IHTMLDocument3::getElementById

 

 

Build date: 11/12/2012

Did you find this helpful?
(1500 characters remaining)

Community Additions

ADD
© 2013 Microsoft. All rights reserved.