Share via


XmlAttribute.NodeValue Property

Definition

Gets or sets the text associated with the node.

public:
 property Platform::Object ^ NodeValue { Platform::Object ^ get(); void set(Platform::Object ^ value); };
IInspectable NodeValue();

void NodeValue(IInspectable value);
public object NodeValue { get; set; }
var object = xmlAttribute.nodeValue;
xmlAttribute.nodeValue = object;
Public Property NodeValue As Object

Property Value

Object

Platform::Object

IInspectable

The text associated with the node.

Implements

Remarks

On retrieval, the value of this attribute is returned as a string. Character and general entity references are replaced with their values.

On setting, this property creates a Text node with the unparsed contents of the string.

This value depends on the NodeType property. The following table describes this dependency.

NodeTypeNodeValue
ElementNull
AttributeValue of attribute
TextContent of the text node
CDATASectionContent of the CDATA Section
EntityReferenceNULL
EntityNULL
ProcessingInstructionEntire content excluding the target
CommentContent of the comment
DocumentNULL
DocumentTypeNULL
DocumentFragmentNULL
NotationNULL

Applies to