I want to make a key combination press on click

Viewed 22

I want to make Key Combination Press. (WINDOWS + SHIFT + LEFT Arrow) On click on a button. I have searched on Internet as well and tried as well.

http://jsfiddle.net/z_acharki/wsytmn10/1/

Taken help from this link.

    $("body").keydown(function(e) {
      var code = (e.keyCode ? e.keyCode : e.which);
    
      if (code == 37) {
        if (e.91) {
          alert("Ctrl+C was pressed!!");
        }
      }
    });
    
    var e = jQuery.Event("keydown");
    
    e.which = 16; //Keycode of SHIFT
    e.which = 37; //Keycode of Left Arrow
    e.which = 91; // Keycode of Windows button.
$("body").trigger(e);

I am failed. I am not too much good at jquery. Basically i want to shift display to second monitor in Chrome Browser. WINDOWS + SHIFT + LEFT ARROW is the shorkey of the Movement of Display

0 Answers
Related