Export (0) Print
Expand All

getNamedItem method

Gets an IHTMLDOMAttribute specified with the IHTMLDOMAttribute2::name property, by using the IHTMLAttributeCollection interface.

Document Object Model (DOM) Level 3 Core Specification, Section 1.4

 

Syntax


IHTMLDOMAttribute retVal = object.getNamedItem(bstrName);

Parameters

bstrName [in]

Type: BSTR

A BSTR that specifies the name of the IHTMLDOMAttribute to get.

Standards information

Remarks

If the IHTMLDOMAttribute applies to an element but is not specified, this method returns the IHTMLDOMAttribute with the specified name set to an empty string.

If the IHTMLDOMAttribute does not apply to the element and is not specified, then an error is returned.

If the IHTMLDOMAttribute does not apply to the element and is specified, then the IHTMLDOMAttribute with the specified name is returned.

Windows Internet Explorer 8 and later. In IE8 Standards mode, the IHTMLAttributeCollection4::getNamedItem method does not create Attr objects that do not exist in the collection; it returns NULL when an IHTMLDOMAttribute is not found. For more information on IE8 mode, see Defining Document Compatibility.

IHTMLAttributeCollection4::getNamedItem was introduced in Microsoft Internet Explorer 6.

 

 

Community Additions

ADD
Show:
© 2014 Microsoft