Copy link to clipboard
Copied
Hi All, I am trying to define a command and add a shortcut to it. I want to use Control+/ but I can't figure out the correct syntax. I tried this, but it didn't work:
cmd = topMenu.DefineAndAddCommand (40, "MyCommandCmd", "My Command", "\^/");
Copy link to clipboard
Copied
Hi Rick,
try this:
cmd = topMenu.DefineAndAddCommand (40, "MyCommandCmd", "My Command", "^j"); // j for the key
Copy link to clipboard
Copied
Rick, a problem might be that the / is used in command definitions to introduce special keys in wincmds.cfg:
<Modify DeleteBackToPrevWordEnd <KeySequence ^/BkSp > >
Might it help by doubling it?
cmd = topMenu.DefineAndAddCommand (40, "MyCommandCmd", "My Command", "\^//");