Clipboard paste via xtype not working in google mail

I’m using the Chrome extension and principally the xtype function to create a new email in Google Mail. I have an image and a link previously stored in the clipboard. When I paste this into Word both the image and the link appear in the document. When I try to use xtype to issue a Mac keyboard paste command ${KEY_CMD+KEY_V} it just pastes a lowercase v into the mail message. When I hit CMD-V on the keyboard, it pastes the content in correctly. I can’t get xtype to replicate the keystrokes… Any thoughts?

Hi, I confirmed the issue with the Command key. We will look into this ASAP.

Meanwhile, there are two workarounds:

  • If you need to get info from the clipboard into a field, you can access the clipboard value with the !clipboard variable.

  • You can simulate right-click and select “Paste” from the context menu, by sending a few KEY_DOWN and one KEY_ENTER. See this screencast:

Code:

{
  "Name": "copy and paste1-1",
  "CreationDate": "2020-2-14",
  "Commands": [
    {
      "Command": "store",
      "Target": "hello test",
      "Value": "!clipboard"
    },
    {
      "Command": "open",
      "Target": "https://anotepad.com/",
      "Value": ""
    },
    {
      "Command": "bringBrowserToForeground",
      "Target": "",
      "Value": ""
    },
    {
      "Command": "XClick",
      "Target": "id=edit_textarea",
      "Value": ""
    },
    {
      "Command": "XClick",
      "Target": "id=edit_textarea",
      "Value": "#right"
    },
    {
      "Command": "XType",
      "Target": "${KEY_DOWN}${KEY_DOWN}${KEY_DOWN}",
      "Value": ""
    },
    {
      "Command": "XType",
      "Target": "${KEY_ENTER}",
      "Value": ""
    }
  ]
}

CMD+V test (same issue as you):