function checkFilterCheckbox(tableIndex, cClass)
 {
     var Checkbox = document.getElementById( cCheckID + tableIndex + cClass + "\r\n" );
     var TR = Checkbox.parentNode.parentNode.parentNode;

     if ($(TR).hasClass("filterRadio")) {
       var Checks = TR.getElementsByTagName( "A" );

       for ( var j=0; j < Checks.length; j++)
         Checks.firstChild.data = cUnchecked;

       Checkbox.lastChild.data = cChecked;
     }
     else
       Checkbox.lastChild.data = (Checkbox.lastChild.data == cUnchecked)?cChecked:cUnchecked;

     var HdTR = TR.parentNode.getElementsByTagName( "TR" );
     var aClass = new Array();
     var bChecked = new Array();

     for ( var i = 0, iCheck = 0; i < HdTR.length; i++ ) {
       if ($(HdTR).hasClass("filterGroup")) {
         var bAnyChecked = false;
         var Checks = HdTR.getElementsByTagName( "A" );

         for ( var j=0; j < Checks.length; j++){
           aClass = Checks.id.charAt(Checks.id.length-1);
           bChecked = Checks.firstChild.data == cChecked;
           bAnyChecked = bAnyChecked || bChecked;
         }

         if (!bAnyChecked && $(HdTR).hasClass("filterAll") )
           for ( var j=0; j < Checks.length; j++)
             bChecked = true;

         iCheck += Checks.length;
       }
     }

     applyFilter(tableIndex, aClass, bChecked);
 }