ASP.NET 2.0 All-In-One Desk Reference For Dummies®
by Doug Lowe, Jeff Cogswell, Ken Cox - Microsoft MVP
Chapter 4. Displaying and Editing Detail Data
In This Chapter
✓ | Viewing data with a DetailsView control |
✓ | Managing a DetailsView and a GridView together |
✓ | Editing data with a DetailsView control |
✓ | Viewing data in a custom layout with a FormView control |
✓ | Managing a FormView and a GridView together |
✓ | Editing data in a custom layout with a FormView control |
Acommon way to display data on a computer screen is to show only a single record arranged in a table format, with a left column showing names of the fields, and a right column showing the data in the fields. The standard result looks something like this:
Name | Abraham Lincoln |
Position | President |
Salary | $5,000 |
This is quite different from showing records from a result set, where you show many records, each on a single row. Instead, in the case at hand, only a single record is visible, and the single record does not occupy a single row on the screen.
In this chapter, I show you different ways to display a single record of data on the screen. Please note that throughout this chapter I typically use the term row (as I have throughout the book) to mean a single record in a result set. At times such terminology can become confusing — in which case, I use the term record just to keep my words unambiguous. Similarly, I sometimes use the term field instead of column to avoid ambiguity.

All code listings used in this book are available for download at www.dummies.com/go/aspnetaiofd ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access