ASP.NET 2.0 enables a declarative solution for data binding which requires no code at all for the most common data scenarios, such as:
Data Source Controls:
Data source controls have no rendering, but instead represent a particular backend data store, for example a database, business object, XML file, or XML Web Service. Data source controls also enable rich capabilities over data - such as sorting, paging, filtering, updating, deleting, and inserting - that data-bound UI controls can automatically use. ASP.NET includes the following server controls out-of-the-box
Data Bound controls are UI controls that render data as markup to the requesting client device or browser. A data-bound control can auto-bind to data exposed from a data source and will fetch data at the appropriate time in the page request lifecycle. These controls can optionally take advantage of data source capabilities such as sorting, paging, filtering, updating, deleting, and inserting. A data-bound control connects to a data source control through its DataSourceID property. You may be familiar with some of the data-bound controls in ASP.NET v1.x, such as DataGrid, DataList, Repeater, and list controls like DropDownList. ASP.NET 2.0 contains several new data-bound controls as well, such as:
- Selecting and displaying data
- Sorting, Paging and Caching Data
- Updating, Inserting and Deleting Data
- Filtering or Master-Details Using Parameters
Data Source Controls:
Data source controls have no rendering, but instead represent a particular backend data store, for example a database, business object, XML file, or XML Web Service. Data source controls also enable rich capabilities over data - such as sorting, paging, filtering, updating, deleting, and inserting - that data-bound UI controls can automatically use. ASP.NET includes the following server controls out-of-the-box
- SqlDataSource : Enables binding to a SQL database represented by an ADO.NET provider, such as Microsoft™ SQL Server, OLEDB, ODBC, or Oracle.
- ObjectDataSource : Enables binding to a middle-tier object such as a data access layer or business component.
- AccessDataSource : Enables binding to a Microsoft™ Access (Jet) database.
- SiteMapDataSource : Enables binding to the hierarchy exposed by an ASP.NET 2.0 site navigation provider.
- XmlDataSource : Enables binding to an XML file or document.
Data Bound controls are UI controls that render data as markup to the requesting client device or browser. A data-bound control can auto-bind to data exposed from a data source and will fetch data at the appropriate time in the page request lifecycle. These controls can optionally take advantage of data source capabilities such as sorting, paging, filtering, updating, deleting, and inserting. A data-bound control connects to a data source control through its DataSourceID property. You may be familiar with some of the data-bound controls in ASP.NET v1.x, such as DataGrid, DataList, Repeater, and list controls like DropDownList. ASP.NET 2.0 contains several new data-bound controls as well, such as:
- GridView : Renders data in a grid format. This control is an evolution of the DataGrid control, and can automatically take advantage of data source capabilities.
- DetailsView : Renders a single data item in a table of label/value pairs, similar to the form view in Microsoft™ Access. This control can also automatically take advantage of data source capabilities.
- FormView : Renders a single data item at a time in a form defined by a custom template. Renders a single data item in a table of label/value pairs, similar to the form view in Microsoft™ Access. This control can also automatically take advantage of data source capabilities.
- TreeView : Renders data in a hierarchical tree view of expandable nodes.
- Menu : Renders data in a hierarchical dynamic menu