<td><input id=chkall type=checkbox onclick=chkAll(); />全选/取消</td>
<script type=text/javascript>
function chkAll()
{
//debugger;
var chkall= documentall[chkall];
var chkother= documentgetElementsByTagName(input);
for (var i=;i<chkotherlength;i++)
{
if( chkother[i]type==checkbox)
{
if(chkother[i]idindexOf(TreeView)>)
{
if(chkallchecked==true)
{
chkother[i]checked=true;
}
else
{
chkother[i]checked=false;
}
}
}
}
}
</script>