System.Xml.Schema.XmlSchemaValidator.ValidateEndElement Method

Verifies if the text content of the element specified is valid according to its data type.

Syntax

public object ValidateEndElement (XmlSchemaInfo schemaInfo, object typedValue)

Parameters

schemaInfo
An System.Xml.Schema.XmlSchemaInfo object whose properties are set on successful validation of the text content of the element. This parameter can be null.
typedValue
The typed text content of the element.

Returns

The parsed, typed simple content of the element.

Remarks

Note:

If you are validating against the xs:key, xs:keyref, or xs:unique identity constraints, do not use the XmlSchemaValidator.ValidateEndElement(XmlSchemaInfo, object) method overload. Instead, call the erload:System.Xml.Schema.XmlSchemaValidator.ValidateText method and pass it the value of the element. Then call the XmlSchemaValidator.ValidateEndElement(XmlSchemaInfo) method overload, which takes System.Xml.Schema.XmlSchemaInfo as an argument, to verify that the text content of the element is valid according to its data type.

The following are important notes to consider when using the XmlSchemaValidator.ValidateEndElement(XmlSchemaInfo, object) method.

Requirements

Namespace: System.Xml.Schema
Assembly: System.Xml (in System.Xml.dll)
Assembly Versions: 2.0.0.0, 4.0.0.0
Since: .NET 2.0