NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

ValidationDelegate Delegate

Represents the method that handles validation error events of the System.NewXml.XmlTextReaderClass.

[Visual Basic]
Public Delegate Sub ValidationDelegate( _
   ByVal hr As Integer, _
   ByVal reason As String _
)
[C#]
public delegate void ValidationDelegate(
   int hr,
   string reason
);
[C++]
public __gc __delegate void ValidationDelegate(
   int hr,
   String* reason
);

[JScript] In JScript, you can use the delegates in the NGWS frameworks, but you cannot define your own.

Parameters [Visual Basic, C#, C++]

The declaration of your event-handling method must have the same parameters as the ValidationDelegate delegate declaration.

hr
Error code.
reason
Description of the error.

Remarks

[To be supplied.]

Requirements

Namespace: System.NewXml

Assembly: System.Xml.dll

Example

The following is a simple example of a validation callback method:

[C++]
    private void ValidationCallback(int hr, String msg)
    {
        Console.WriteLine("");
        Console.WriteLine("hr: " + hr);
        Console.WriteLine(msg);
    }

See Also

System.NewXml Namespace