Databases Reference
In-Depth Information
Summary
Entity templates are a special type of ASP.NET user control, used by Dynamic Data to
encapsulate presentation logic of displaying a single entity instance or, using database
terminology, a single row from database table. Entity templates are used with web pages
that display a single item at a time, typically in a form-based format.
By default, Dynamic Data expects to find entity templates in the
DynamicData\EntityTemplates folder of the web application. A set of default entity
templates is provided out of the box in this folder by the Dynamic Data web project
templates in Visual Studio 2010. The default templates dynamically generate labels and
controls for any given entity based on the metadata information extracted from a LINQ-
based data model, such as Entity Framework or LINQ to SQL.
Metadata information defines the list of columns that should be displayed based on the
DisplayAttribute in the System.ComponentModel.DataAnnotations namespace. Data
annotation attributes can be used to change display names and order of the columns on a
page produced by the default entity templates. When fine-grained control of the form
layout is required, custom entity templates can be created.
 
Search WWH ::




Custom Search