﻿
////now create the event handler function to process the event
//function ShortcutKeys() {
//    
//    //first, tell the browsers to react to the event
//    if (document.captureEvents && Event.KEYUP) {
//        //remove this part if you do not need Netscape 4 to work
//        document.captureEvents(Event.KEYUP);
//    }
//    var e = document.onkeyup;    
//          
//    if (!e) {
//        //if the browser did not pass the event information to the
//        //function, we will have to obtain it from the event register
//        if (window.event) {
//            //Internet Explorer
//            e = window.event;
//        } else {
//            //total failure, we have no way of referencing the event
//            return;
//        }
//    }
//    if (typeof (e.keyCode) == 'number') {
//        //DOM
//        e = e.keyCode;
//    } else if (typeof (e.which) == 'number') {
//        //NS 4 compatible
//        e = e.which;
//    } else if (typeof (e.charCode) == 'number') {
//        //also NS 6+, Mozilla 0.9+
//        e = e.charCode;
//    } else {
//        //total failure, we have no way of obtaining the key code
//        return;
//    }

//    /*****Actual Logic******/
//    //var e = event.keyCode ? event.keyCode : event.which ? event.which : event.charCode;            
//    if (e == 37) {
//        if (document.getElementById('linkPrevious') != null) {
//            // Left Arrow Key
//            window.location.href = document.getElementById('linkPrevious').href;
//            //document.getElementById('linkPrevious').click();
//        }
////        else if (document.getElementById('ctl00_CC_linkPrevious') != null) {
////            window.location.href = document.getElementById('ctl00_CC_linkPrevious').href;            
////        }
//    }

//    if (e == 39) {
//        if (document.getElementById('linkNext') != null) {
//            // Right Arrow Key
//            window.location.href = document.getElementById('linkNext').href;
//            //document.getElementById('linkNext').click();
//        }
////        else if (document.getElementById('ctl00_CC_linkNext') != null) {
////            window.location.href = document.getElementById('ctl00_CC_linkNext').href;            
////        }
//    }
//}

