I am having problems with ASP.NET?

Shorty2

New member
I have created a drop down list with states to be selected, and I also have a checkbox to add a new state if their state is not listed in the drop down list. I have to hide the checkbox once a state is selected from the drop down list. I am not sure how to do this.

Here is my code for the drop down list:

<tr>
<td class="style5" id="ST">
State</td>
<td class="style4"> <asp:DropDownList ID="ddlState" runat="server"
onselectedindexchanged="ddlState_SelectedIndexChanged"
style="height: 22px">
<asp:ListItem> </asp:ListItem>
<asp:ListItem>MA</asp:ListItem>
<asp:ListItem>DC</asp:ListItem>
<asp:ListItem>CA</asp:ListItem>
<asp:ListItem>IL</asp:ListItem>
<asp:ListItem>KS</asp:ListItem>
<asp:ListItem>TX</asp:ListItem>
<asp:ListItem>TN</asp:ListItem>
<asp:ListItem>NY</asp:ListItem>
<asp:ListItem>UT</asp:ListItem>
<asp:ListItem>FL</asp:ListItem>
</asp:DropDownList></td>

Here is my code for the checkbox to Add New State:

<tr>
<td class="style5" id="AddNST">
Add New State</td>
<td class="style4">


<asp:CheckBox ID="cbNST" runat="server" AutoPostBack="True"
oncheckedchanged="cbNST_CheckedChanged" />
</td>
 
Back
Top