EditorExtension.GetValue<T>(String, ValidationSettings, EventHandler<ValidationEventArgs>, MaskSettings, ref Boolean) Method

Returns a specific editor's value, which is validated based on the passed validation and mask settings, and custom validation logic, and indicates whether the editor value is valid.

Namespace: DevExpress.Web.Mvc

Assembly: DevExpress.Web.Mvc5.v19.2.dll


public static T GetValue<T>(
    string name,
    ValidationSettings validationSettings,
    EventHandler<ValidationEventArgs> validationDelegate,
    MaskSettings maskSettings,
    ref bool isValid
Public Shared Function GetValue(Of T)(
    name As String,
    validationSettings As ValidationSettings,
    validationDelegate As EventHandler(Of ValidationEventArgs),
    maskSettings As MaskSettings,
    ByRef isValid As Boolean
) As T


Name Type Description
name String

A string specifying the editor name (SettingsBase.Name).

validationSettings ValidationSettings

A ValidationSettings object containing the settings that relate to editor validation.

validationDelegate EventHandler<ValidationEventArgs>

A method to which custom validation processing is delegated.

maskSettings MaskSettings

A MaskSettings object containing the editor mask settings.

isValid Boolean

true if the editor value is valid; otherwise, false.

Type Parameters

Name Description


Type Description

An object representing the editor value.


The GetValue<T> method is in effect only for DevExpress editor extensions (i.e. EditorExtension class descendants).

Use the static GetValue<T> method to access the editor value within the controller code.


In order to pass the editor value to the controller, place the editor within the <form> tag (e.g. using the Html.BeginForm Method) and then submit the form to the server.

Note that the client-side validation of user input can prevent the form from being submitted it to server unless the end-user input is valid.

See Also