dropdown list selected index changed
<p>I did my drop down list that get it,s values from database 
and when run the application it did not work and compiler did not see  the code </p>

<p>// aspx</p>

<pre><code>  &lt;asp:UpdatePanel ID="UpdatePanel3" runat="server"&gt;
                 &lt;ContentTemplate&gt;
                       &lt;asp:DropDownList ID="DDlProductFamily" runat="server" 
                         ondatabound="DDlProductFamily_DataBound"  
                         onselectedindexchanged="DDlProductFamily_SelectedIndexChanged"&gt;
                                                &lt;/asp:DropDownList&gt;
                                            &lt;/ContentTemplate&gt;
                                            &lt;Triggers&gt;
                                                &lt;asp:AsyncPostBackTrigger ControlID="DDlProductFamily" EventName="SelectedIndexChanged" /&gt;
                                            &lt;/Triggers&gt;
                                        &lt;/asp:UpdatePanel&gt;
</code></pre>

<p>// cs</p>

<pre><code> protected void DDlProductFamily_SelectedIndexChanged(object sender, EventArgs e)
    {            
        using (SqlConnection Con = Connection.GetConnection())
        {    
            SqlCommand Com = new SqlCommand("SelectThumbByProductFamily", Con);
            Com.CommandType = CommandType.StoredProcedure;
            Com.Parameters.Add(Parameter.NewInt("@ProductCategory_Id",
                DDlProductFamily.SelectedValue.ToString()));
            SqlDataAdapter DA = new SqlDataAdapter(Com);
            DA.Fill(dt);
            DataList1.DataSource = dt;
            DataList1.DataBind();
        }
    }
</code></pre>
