Show theme settings Shopping cart Download trialFree Trial
Change Theme Settings
Change Theme Settings
Themes
 
Show All Themes
v
...v

Editor Templates

v
Update
Clear


DevExpress MVC extensions support standard the ASP.NET MVC templating system. This demo illustrates how to use DevExpress MVC Data Editors for building custom editor templates.

The Html.EditorFor() method is used to display data editors for model data fields using the required template. This method consults the UIHint attribute value or data type to determine which template to render for the given property.

All the custom editor template files are located in the EditorTemplates subfolder in the ~\Views\Shared project folder. Each template file has the same name as a corresponding data type or UIHint attribute value. The template view code in this demo contains the label that displays the property name and the data editor that allows you to edit the required field.

Collapse/Expand
Local Copy of this Demo
To inspect the source code for this demo on your machine, you must first install our components via the DevExpress Component Installer.
You can open a local copy of this online demo directly from this webpage (if using v20.2.8, 21.1.4 or higher).
Open CS Solution
The source code files for this demo are installed (by default) in the following directory:
\Users\Public\Documents\DevExpress Demos XX.X\Components\ASP.NET\CS\MVCxDataEditorsDemos