Xtype, google spreadsheet and keyboard combination

Good morning, excuse my English.

I am trying to run a macro on google spreadsheet with a keyboard combination, for example: ctrl + shift + alt + 1. To do this I use: “Xtype” “$ {KEY_CTRL + KEY_ALT + KEY_SHIFT + KEY_1}”.

The problem is that it does not execute the combination, what it does is write in the cell “$ {KEY_CTRL + KEY_ALT + KEY_SHIFT + KEY_1}”

I know I could solve it working with csv but I have to do it with google spreadsheet.

Any solution?

THANK YOU VERY MUCH.

What does the combination KEY_CTRL + KEY_ALT + KEY_SHIFT + KEY_1 do in google sheets? I tried it manually and nothing happened :wink:

It is a keyboard shortcut to execute a google spreadsheet macro, before you must configure it.

In any case, if I use “Xtype” “$ {KEY_CTRL + KEY_V}” the same thing happens.

THANKS !!

THIS DOES THE KEY COMBINATION KEY_CTRL + KEY_ALT + KEY_SHIFT + KEY_1:

I KNOW I CAN DO IT IN THIS OTHER WAY, BUT IT’S VERY SLOW.

I just tested XType with Google Sheets and it works for me:

Did you make sure you have the focus on the right cell?

My test macro:

{
  "Name": "google1",
  "CreationDate": "2020-4-24",
  "Commands": [
    {
      "Command": "store",
      "Target": "Hello!",
      "Value": "!clipboard"
    },
    {
      "Command": "pause",
      "Target": "2000",
      "Value": ""
    },
    {
      "Command": "XType",
      "Target": "${KEY_CTRL+KEY_V}",
      "Value": ""
    }
  ]
}

If it works for me, I had a space after dollar symbol, when I tried “CTRL + V”. However, “${KEY_CTRL + KEY_ALT + KEY_SHIFT + KEY_0}” still does not work.
Maybe too many keys at the same time?

I’ve also noticed that the Google sheet macro doesn’t work if I use the numeric keypad, but it does work if I use the numbers on the alphanumeric keypad.

THANKS!!

Hmm… I confirmed this issue: Up to 3 special keys are supported, so it should work. And it works ok on the keyboard test page:

But it fails in Google Sheets (Macro does not start):

Other things like CTRL+SHIFT+5 work fine. Here tested with a browser extension like Nimbus:

Workaround: Until we solve this issue you can use the “XRun + VBS sendkeys” workaround described here: