runat="server"
ProviderName="System.Data.SqlClient"
DataSourceMode="DataReader"
ConnectionString="<%$ ConnectionStrings:AdventureWorks %>"
SelectCommand="Select ProductSubcategoryID, Name from Production.ProductSubcategory">
Categories:
DataSourceID="categoriesSource"
DataValueField="ProductSubcategoryID"
DataTextField="Name"
AutoPostBack="true"
ID="lstCategories" />
runat="server"
ProviderName="System.Data.SqlClient"
DataSourceMode="DataReader"
ConnectionString="<%$ ConnectionStrings:AdventureWorks %>"
SelectCommand="Select ProductID, Name, ProductNumber, StandardCost from Production.Product Where ProductSubcategoryID=@ProductSubcategoryID">
ControlID="lstCategories"
Name="ProductSubcategoryID"
PropertyName="SelectedValue" />
HeaderStyle-HorizontalAlign="Center" HeaderStyle-Font-Bold="True"
HeaderStyle-BackColor="blue" HeaderStyle-ForeColor="White" />