ValidationRulesFactory.AddPattern() Method
Adds a validation rule that checks if an editor’s value matches a specified pattern.
Namespace: DevExtreme.AspNet.Mvc.Factories
Assembly: DevExtreme.AspNet.Core.dll
Declaration
public PatternRuleBuilder AddPattern()
Returns
Type | Description |
---|---|
PatternRuleBuilder | A PatternRuleBuilder instance. |
Remarks
Refer to Validate Editors Used in Composite Controls for more information.
@(Html.DevExtreme().DataGrid()
.Columns(columns => {
columns.Add().ValidationRules(rules => {
rules.AddPattern()
// call methods to specify nested options
});
})
)
See Also