Important:
This is retired content. This content is outdated and is no longer being maintained. It is provided as a courtesy for individuals who are still using these technologies. This content may contain URLs that were valid when originally published, but now link to sites or pages that no longer exist.
A version of this page is also available for
4/8/2010

Adds the supplied node to the collection.

Script Syntax

Copy Code
var 
objXMLDOMNode = oIXMLDOMNamedNodeMap.setNamedItem(
newItem);

Remarks

Script Parameters

newItem

Object containing the attribute to be added to the collection.

Script Return Value

Object. Returns the attribute successfully added to the collection.

C/C++ Syntax

Copy Code
HRESULT setNamedItem(
  IXMLDOMNode* 
newItem,
  IXMLDOMNode** 
nameItem
);

Remarks

C/C++ Parameters

newItem

[in] Attribute to be added to the collection.

nameItem

[out, retval] Attribute successfully added to the collection. If Null, no object is created.

C/C++ Return Values

S_OK

Value returned if successful.

E_INVALIDARG

Value returned if newItemis Null.

E_FAIL

Value returned if an error occurs.

Requirements

Header msxml2.h, msxml2.idl
Library uuid.lib
Windows Embedded CE Windows CE .NET 4.0 and later

General Remarks

If an attribute already exists with the name in IXMLDOMNode, the supplied replaces the existing attribute. The attribute name appears in its IXMLDOMNodeproperty.

If the newItemnode type is not NODE_ATTRIBUTE, setNamedItemreturns an error. For example, it is not possible to modify entities or notations, which are read-only.

This method applies to the following objects and interfaces:

IXMLDOMNode, and IXMLDOMNamedNodeMap.

500 Internal Server Error

Internal Server Error

The server encountered an internal error or misconfiguration and was unable to complete your request.

Please contact the server administrator at webmaster@systemmanager.forsenergy.ru to inform them of the time this error occurred, and the actions you performed just before this error.

More information about this error may be available in the server error log.

Additionally, a 500 Internal Server Error error was encountered while trying to use an ErrorDocument to handle the request.