GetErrors Method
Collapse the table of content
Expand the table of content

ValidationHelper.GetErrors Method

Returns a list of current validation errors, and optionally lets you specify a list of fields to check.

Namespace:  System.Web.WebPages
Assembly:  System.Web.WebPages (in System.Web.WebPages.dll)

'Declaration
Public Function GetErrors ( _
	ParamArray fields As String() _
) As IEnumerable(Of String)
'Usage
Dim instance As ValidationHelper 
Dim fields As String()
Dim returnValue As IEnumerable(Of String)

returnValue = instance.GetErrors(fields)

Parameters

fields
Type: System.String()
Optional. The names (value of the name attribute) of the user input elements to get error information for. You can specify any number of element names, separated by commas. If you do not specify a list of fields, the method returns errors for all fields.

Return Value

Type: System.Collections.Generic.IEnumerable(Of String)
The list of errors.
Show:
© 2016 Microsoft