check/uncheck checkbox in Jquery
<p>this is my .aspx page where i am using JQuery
Based on the check box checked and  uncheck i should make an div  display and  hide
i here when i am displaying the div tag i am even reseting the dropdown values</p>

<p>but when ever i check/uncheck the checkbox nothing seems happening</p>

<pre><code>&lt;html xmlns="http://www.w3.org/1999/xhtml"&gt;
&lt;head id="Head1" runat="server"&gt;
    &lt;title&gt;Untitled Page&lt;/title&gt;
    &lt;%-- &lt;script type="text/javascript"&gt;
    &lt;script type="text/javascript" src="JScript.js"&gt;&lt;/script&gt;--%&gt;

    &lt;script src="jquery-1.6.2.min.js" type="text/javascript"&gt;&lt;/script&gt;

    &lt;script type="text/javascript"&gt;
    $(document).ready(function() 
    {
    if ($("#CheckBox1").is(':checked')) 
    { 
     $('#divControlGroup').css("display", "block"); 
     $("#ddlcounty option:first").attr("selected", true);

    } 
    else 
    { 
    $('#divControlGroup').css("display", "none"); 

     } 
    })
    &lt;/script&gt;

&lt;/head&gt;
&lt;body&gt;
    &lt;form id="form1" runat="server"&gt;
    &lt;table&gt;
        &lt;tr&gt;
            &lt;td&gt;
                &lt;asp:CheckBox ID="CheckBox1" runat="server" Checked="false" /&gt;
            &lt;/td&gt;
            &lt;td&gt;
                &lt;div id="divControlGroup" runat="server"&gt;
                    &lt;asp:Label ID="Label1" runat="server" Text="Label"&gt;&lt;/asp:Label&gt;
                    &lt;asp:DropDownList ID="ddlcounty" runat="server"&gt;
                        &lt;asp:ListItem Value="0"&gt;Select&lt;/asp:ListItem&gt;
                        &lt;asp:ListItem Value="1"&gt;India&lt;/asp:ListItem&gt;
                        &lt;asp:ListItem Value="2"&gt;US&lt;/asp:ListItem&gt;
                        &lt;asp:ListItem Value="3"&gt;UK&lt;/asp:ListItem&gt;
                    &lt;/asp:DropDownList&gt;
                &lt;/div&gt;
            &lt;/td&gt;
        &lt;/tr&gt;
    &lt;/table&gt;
    &lt;/form&gt;
&lt;/body&gt;
&lt;/html&gt;
</code></pre>

<p>pls  let me know where i amgoing where, any help would be great</p>

<p>Thanks</p>

<p><strong>finally anser for the problem</strong> </p>

<pre><code>&lt;script type="text/javascript"&gt;
    $(document).ready(function() 
    {
     $('#&lt;%= CheckBox1.ClientID %&gt;').change(function() 
    {    
     if($(this).is(':checked')) 
     {       
      $("#divControlGroup").css("display", "block");   
      $("#ddlcounty option:first").attr("selected", true); 
      } 
     else 
        { 
    $("#divControlGroup").css("display", "none"); 
     } 
        })
        });
    &lt;/script&gt;
</code></pre>
