[Expand]General Information
[Expand]WinForms Controls
[Collapse]ASP.NET Controls and MVC Extensions
 [Expand]Prerequisites
 [Expand]What's Installed
 [Expand]Common Concepts
 [Collapse]ASP.NET WebForms Controls
   Getting Started
  [Collapse]Grid View
   [Expand]Product Information
    Getting Started
   [Expand]Fundamentals
   [Expand]Concepts
    ASPxGridView Designer
   [Expand]Visual Elements
   [Collapse]Examples
     How to: Add an Unbound Column to Supply Additional Data
     How to: Add and Initialize a New Row
     How to: Add Custom Filter Values to the Filter Dropdown
     How to: Bind the ASPxGridView to Data Created at Runtime (DataTable)
     How to: Bind to an ArrayList
     How to: Calculate Custom Total Summaries
     How to: Change the Style Settings of Individual Data Cells
     How to: Create an ASPxGridView at Runtime
     How to: Create and Customize a Group Summary
     How to: Create Custom Command Buttons
     How to: Create Edit Form Template at Runtime
     How to: Create Total Summaries
     How to: Delete Selected Rows
     How to: Display a Context Menu For Column Headers
     How to: Display Images within Preview Rows
     How to: Display Master-Detail Data (XPO)
     How to: Display Real-Time Data
     How to: Dynamically Change Images Displayed Within Data Cells
     How to: Dynamically Display the Focused Row's Values Outside the ASPxGridView
     How to: Export ASPxGridView Data as a PDF
     How to: Filter Data by Multiple Columns
     How to: Filter Records
     How to: Generate Persistent Objects for Existing Data Tables
     How to: Hide Expand Buttons for Master Rows That Have Empty Details
     How to: Implement Custom Grouping
     How to: Implement Custom Sorting
     How to: Implement Data Editing When a Grid is Bound to a Table Created At Runtime
     How to: Implement Master-Detail at Runtime (XPO)
     How to: Obtain Server Data From the Client
     How to: Present Data in Cards
     How to: Provide Custom Display Text for Data Cells
     How to: Render a Different Content From Default Exporting
     How to: Save and Restore the ASPxGridView's Layout
     How to: Save Changes and Switch to Browse Mode by Clicking ENTER
     How to: Select Rows That Contain the Specified Value
     How to: Show Detail Information in a Separate ASPxGridView
     How to: Sort Groups by Summary Values
     How to: Switch ASPxGridView to an Edit Mode by Double-Clicking a Row
     How to: Use a Hyperlink Whose Argument Depends on Several Cell Values in the ASPxGridView
     How to: Validate Data On the Client
     How to: Validate Rows
   [Expand]Member Tables
   [Expand]ASPxGridView - Animated Images
  [Expand]Tree List
  [Expand]Card View
  [Expand]Reporting
  [Expand]Chart Control
  [Expand]Pivot Grid
  [Expand]Spreadsheet
  [Expand]Rich Text Editor
  [Expand]Scheduler
  [Expand]Site Navigation and Layout
  [Expand]HTML Editor
  [Expand]Gauges
  [Expand]Vertical Grid
  [Expand]Data Editors
  [Expand]Docking and Popups
  [Expand]File Management
  [Expand]Data and Image Navigation
  [Expand]Multi-Use Site Controls
  [Expand]Spell Checker
  [Expand]Query Builder
 [Expand]ASP.NET MVC Extensions
 [Expand]Localization
 [Expand]Redistribution and Deployment
  Get More Help
 [Expand]API Reference
[Expand]ASP.NET Bootstrap Controls
[Expand]ASP.NET Core Bootstrap Controls
[Expand]WPF Controls
[Expand]Xamarin Controls
[Expand]Windows 10 App Controls
[Expand]Office File API
[Expand]Reporting
[Expand]Report and Dashboard Server
[Expand]Dashboard
[Expand]eXpressApp Framework
[Expand]CodeRush
[Expand]CodeRush Classic
[Expand]Cross-Platform Core Libraries
[Expand]Tools and Utilities
 End-User Documentation

How to: Validate Data On the Client

This example shows how to implement client-side validation when using custom editors within the Edit Form's template.

To enable the client-side validation, the standard Update button is replaced with a custom button. The custom button's Click event is handled to validate data. If data is valid, the grid's client-side ASPxClientGridView.UpdateEdit method is called.

The editor's validation settings can be accessed and specified using the ASPxEdit.ValidationSettings property. In this example, empty strings are not allowed. In this instance, if the validation fails, error icons are displayed next to the editors with invalid values.

To learn more, see Edit Form Validation (Templates).

The image below shows the result:

Is this topic helpful?​​​​​​​