Gets or sets the data retrieval mode that the System.Web.UI.WebControls.SqlDataSource control uses to fetch data.
Documentation for this section has not yet been entered.
The data retrieval mode identifies how a System.Web.UI.WebControls.SqlDataSource control retrieves data from the underlying database.
When the SqlDataSource.DataSourceMode property is set to the SqlDataSourceMode.DataSet value, data is loaded into a System.Data.DataSet object and stored in memory on the server. This enables scenarios where user interface controls, such as System.Web.UI.WebControls.GridView, offer sorting, filtering, and paging capabilities.
When the SqlDataSource.DataSourceMode property is set to the SqlDataSourceMode.DataReader value, data is retrieved by a System.Data.IDataReader object, which is a forward-only, read-only cursor. The specific type of the System.Data.IDataReader object depends on the NET data provider that the System.Web.UI.WebControls.SqlDataSource uses, which is identified by the SqlDataSource.ProviderName property. By default, the System.Web.UI.WebControls.SqlDataSource control uses the provider for Microsoft SQL Server, the System.Data.SqlClient, and the data reader is a System.Data.SqlClient.SqlDataReader object.
If you change the SqlDataSource.DataSourceMode property, the System.Web.UI.IDataSource.DataSourceChanged event is raised, causing any controls that are bound to the System.Web.UI.WebControls.SqlDataSource to rebind.
The value of the SqlDataSource.DataSourceMode property is stored in view state.