Edit

Share via


ValidationEventHandler Delegate

Definition

Represents the callback method that will handle XML schema validation events and the ValidationEventArgs.

C#
public delegate void ValidationEventHandler(object? sender, ValidationEventArgs e);
C#
public delegate void ValidationEventHandler(object sender, ValidationEventArgs e);

Parameters

sender
Object

The source of the event.

Note Determine the type of a sender before using it in your code. You cannot assume that the sender is an instance of a particular type. The sender is also not guaranteed to not be null. Always surround your casts with failure handling logic.

e
ValidationEventArgs

The event data.

Extension Methods

GetMethodInfo(Delegate)

Gets an object that represents the method represented by the specified delegate.

Applies to

Product Versions
.NET Core 2.0, Core 2.1, Core 2.2, Core 3.0, Core 3.1, 5, 6, 7, 8, 9
.NET Framework 1.1, 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
.NET Standard 2.0, 2.1