﻿// JScript File


document.onkeyup = KeyCheck;       


function KeyCheck(e)

{

   var KeyID = (window.event) ? event.keyCode : e.keyCode;


   switch(KeyID)

   {
    /*
      case 16:

      document.Form1.KeyName.value = "Shift";

      break; 

      case 17:

      document.Form1.KeyName.value = "Ctrl";

      break;

      case 18:

      document.Form1.KeyName.value = "Alt";

      break;

      case 19:

      document.Form1.KeyName.value = "Pause";

      break;
    */
      case 37://left arrow

        
        var div=document.getElementById('prodNavLinks');
        if(div!=null)
        {
            var newLocation= div.childNodes[0].href;
            window.location=newLocation;
        }

      break;
      
      case 39://right arrow

        
        var div=document.getElementById('prodNavLinks');
        if(div!=null)
        {
            var newLocation= div.childNodes[4].href;
            window.location=newLocation;
        }
        break;
        /*
      case 38:

      var div=document.getElementById('prodNavLinks');
      var i=0;
      for( i=0; i<div.childNodes.length;i++ )
      {
        alert(i);
      }

      break;
      

      break;

      case 40:

      document.Form1.KeyName.value = "Arrow Down";

      break;*/
   }

}


