Exposes an array of IValidator references. This class cannot be inherited.
Assembly: System.Web (in System.Web.dll)
Each reference is associated with a validation server control contained on the requested page. These controls add themselves to this collection when the Init event of the Page object is handled. They remove themselves when the Unload event of the Page object is handled. The Page class inherits both of these methods from the Control class.
You can access this collection, its methods, and its properties through the Page.Validators property. If the tested condition of any validator in this collection fails, the Page.IsValid property is set to false.
' Get 'Validators' of the page to myCollection. Dim myCollection As ValidatorCollection = Page.Validators ' Get the Enumerator. Dim myEnumerator As IEnumerator = myCollection.GetEnumerator() ' Print the values in the ValidatorCollection. Dim myStr As String = " " While myEnumerator.MoveNext() myStr += myEnumerator.Current.ToString() myStr += " " End While messageLabel.Text = myStr
Windows 7, Windows Vista, Windows XP SP2, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP Starter Edition, Windows Server 2008 R2, Windows Server 2008, Windows Server 2003, Windows Server 2000 SP4, Windows Millennium Edition, Windows 98
The .NET Framework and .NET Compact Framework do not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.