我在vb.net代碼中有一些複選框。如何確定是否選中了任何複選框?
<tr>
<td colspan="2">
<asp:CheckBox ID="chkbxCreateAmendOrg" runat="server" Checked="False" Text="Create/Amend Organisation" />
</td>
<td colspan="2">
<asp:CheckBox ID="chkbxCreateAmendCPUser" runat="server" Checked="False" Text="Create/Amend CP User" />
</td>
</tr>
<tr>
<td colspan="2">
<asp:CheckBox ID="chkbxDeleteOrg" runat="server" Checked="False" Text="Delete Organisation" />
</td>
<td colspan="2">
<asp:CheckBox ID="chkbxDeleteCPUser" runat="server" Checked="False" Text="Delete CP User" />
</td>
</tr>
我想提醒用戶,如果他們沒有選擇至少一個。我可以有這個jQuery代碼
但是,asp.net用css樣式的span標記包裝複選框。 if($('span> input ... – 2009-09-11 15:14:55
是的,但是這個選擇器會查找文檔上的所有複選框。 – CMS 2009-09-11 15:16:48
它不適用於我,請你看看 – 2009-09-11 15:52:17