Tuesday, 20 September 2011

data controls in asp.net

DataList control

The DataList control displays data in a format that you can define using templates and styles. The DataList control is useful for data in any repeating structure, such as a table. The DataList control can display rows in different layouts, such as ordering them in columns or rows. Optionally, you can configure the DataList control to allow users to edit or delete information. You can also customize the control to support other functionality, such as selecting rows.

DetailsView control
The DetailsView control gives you the ability to display, edit, insert, or delete a single record at a time from its associated data source. By default, theDetailsView control displays each field of a record on its own line. TheDetailsView control is typically used for updating and inserting new records, often in a master/detail scenario where the selected record of the master control determines the record to display in the DetailsView control. The DetailsViewcontrol displays only a single data record at a time, even if its data source exposes multiple records. The DetailsView control does not support sorting.

FormView control

The FormView control gives you the ability to work with a single record from a data source, similar to the DetailsView control. The difference between theFormView and the DetailsView controls is that the DetailsView control uses a tabular layout where each field of the record is displayed as a row of its own. In contrast, the FormView control does not specify a pre-defined layout for displaying the record. Instead, you create a template containing controls to display individual fields from the record. The template contains the formatting, controls, and binding expressions used to create the form.
The FormView control is typically used for updating and inserting new records, and is often used in master/detail scenarios where the selected record of the master control determines the record to display in the FormView control. 

GridView control

A recurring task in software development is to display tabular data. ASP.NET provides a number of tools for showing tabular data in a grid, including theGridView control. With the GridView control, you can display, edit, and delete data from many different kinds of data sources, including databases, XML files, and business objects that expose data.

ListView control

The ListView control is useful for displaying data in any repeating structure, similar to the DataList and Repeater controls. Unlike those controls, the ListView control supports edit, insert, and delete operations as well as sorting and paging. The paging functionality is provided for ListView by the new DataPager control.
The ListView control is a highly customizable control that enables you to use templates and styles to define the control's UI. Like the Repeater, DataList, and FormView controls, templates in the ListView control are not predefined to render specific UI in the browser.



Post a Comment

Subscribe to Post Comments [Atom]

Links to this post:

Create a Link

<< Home