var instance = new GC.Spread.Commands.CommandManager(context); var value; // Type: any value = instance.setShortcutKey(commandName, key, ctrl, shift, alt, meta);
Parameters
- commandName
- The command name, setting commandName to undefined removes the bound command of the shortcut key.
- key
- The key code, setting the key code to undefined removes the shortcut key of the command.
- ctrl
true
if the command uses the Ctrl key; otherwise,false
.- shift
true
if the command uses the Shift key; otherwise,false
.- alt
true
if the command uses the Alt key; otherwise,false
.- meta
true
if the command uses the Command key on the Macintosh or the Windows key on Microsoft Windows; otherwise,false
.