BaseValidator.Validate BaseValidator.Validate BaseValidator.Validate BaseValidator.Validate Method

定义

对关联的输入控件执行验证并更新 IsValid 属性。Performs validation on the associated input control and updates the IsValid property.

public:
 virtual void Validate();
public void Validate ();
abstract member Validate : unit -> unit
override this.Validate : unit -> unit
Public Sub Validate ()

实现

示例

有关的示例Validate方法,用于派生类中,请参阅CompareValidator类概述。For an example of the Validate method used in a derived class, see the CompareValidator class overview.

注解

使用Validate方法关联的输入控件执行验证。Use the Validate method to perform validation on the associated input control. 此方法允许您以编程方式对输入控件执行验证。This method allows you to programmatically perform validation on the input control. IsValid属性会自动更新带有验证结果。The IsValid property is automatically updated with the validation results.

适用于

另请参阅