function mw_chkboxselectortb_set_val_all(tbl,checked,celcrt) {
	
	if (!celcrt){
		celcrt=0;
	}
	for (i=0;i<tbl.rows.length;i++){
		var cell=tbl.rows[i].cells[celcrt];
		var chkbox=mw_chkboxselectortb_get_chkbox(cell);
		if (chkbox){
			chkbox.checked=checked;
		}
	}
	
}
function mw_chkboxselectortb_get_chkbox(cell) {
	var inputs= cell.getElementsByTagName("input");
	if(inputs){
		for (x=0;x<inputs.length;x++){
			if (inputs[x].type=="checkbox"){
				return 	inputs[x];
			}
		}
	}
}
function mw_chkboxselectortb_set_val_all_fromchk(chk,celcrt) {
	var tbl=mw_dom_get_parent_by_tagname(chk,"table");
	if (tbl){
		mw_chkboxselectortb_set_val_all(tbl,chk.checked,celcrt);
	}
}


