The following code example demonstrates how to use to use a DetailsView control in combination with a GridView control for a simple master-detail scenario. It displays the details of an item selected in the GridView control.
Visual Basic
<%@ Page Language="VB" %>
ASP.NET Example
C#
<%@ Page Language="C#" %>
ASP.NET Example
The following code example demonstrates how to use the DetailsView control to add, delete, and edit records.
Visual Basic
<%@ Page Language="VB" %>
DetailsView Example
C#
<%@ Page Language="C#" %>
DetailsView Example
The following code example demonstrates how to declaratively add row fields to the DetailsView control.
Visual Basic
<%@ Page Language="VB" %>
ASP.NET Example