                 selectColumnGroupHeader(newSelectedHeaderInfo);
              }
           }
-          else if (event.keyCode == Keyboard.SPACE)
+          else if (keyCode == Keyboard.SPACE)
           {
               if (sortableColumns && 
                   selectedHeaderInfo.column.colNum != -1 && !isNaN(selectedHeaderInfo.column.colNum)

            }
            event.stopImmediatePropagation();
        }
        else if (event.ctrlKey && event.shiftKey && event.keyCode == Keyboard.RIGHT)
        {
            // Right Arrow has no effect on leaf items. Closed branch items are opened. 
            //Opened branch items select the first child.

          }
          // horizontal scrolling when focus is on header
          else if ( event.shiftKey
                  && (keyCode == Keyboard.PAGE_UP
                     || keyCode == Keyboard.PAGE_DOWN) )
          {
             moveSelectionHorizontally(keyCode, event.shiftKey, event.ctrlKey);
          }
        
          // don't we allow vertical scrolling when focus is on the header?
