hi,
I am using .net 1.1 version.
The problem is i have used one datagrid which contains some data columns and one checkbox column.
Datagrid contains nearly 50 records and 50 checkboxes.(i.e) each record contains checkbox.
below the datagrid an image button is placed.if i didn't select any checkboxes and click on the image button it should tell please select any two checkboxes for compare.
but i am using .net 1.1 so please any one help me....
i need the javascript code for how to check whether the checkbox is checked or not...
Regards,
Prakash
Loading
Master BillaPosted Aug 14, 2009, 5:22 AM
You need use the JAVA script to this
<script type="text/javascript">
function SelectAll(id) {
var frm = document.forms[0];
for (i=0;i
if (frm.elements[i].type == "checkbox") {
if(document.getElementById(id).checked==true)
{
alert(document.getElementById(id).value);
}
}
}
script>
just more details here
http://wiki.asp.net/page.aspx/281/check-uncheck-checkboxes-in-gridview-using-javascript/
thank you
Raghavendra UPosted Aug 14, 2009, 5:12 AM