XPathNavigator.IsEmptyElement Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

When overridden in a derived class, gets a value indicating whether the current node is an empty element without an end element tag.

Namespace:   System.Xml.XPath
Assembly:  System.Xml (in System.Xml.dll)

public abstract bool IsEmptyElement { get; }

Property Value

Type: System.Boolean

true if the current node is an empty element; otherwise, false.

This property enables you to determine the difference between the following different elements.

Element

IsEmptyElement Value

<item num="123"/>

true

<item num="123">test</item>

false

<item num="123"></item>

false

.NET Framework
Available since 1.1
Silverlight
Available since 4.0
Return to top
Show: