# Keyboard Shortcuts in paclets?

I’m trying to add simple keyboard shortcuts (together with menu item) to my paclet through FrontEndExecute which works fine in notebook, but as soon as I put it into my paclet and import it the menu item is stripped from the keyboard shortcut. Is this due to security requirements on paclets or is there perhaps a way around it? I know about KeyEventTranslations.tr but I’d rather not use it.

FrontEndExecute[FrontEndAddMenuCommands["DuplicatePreviousOutput",

• Try to replace MenuKey and Modifiers with SystemMenuKey and SystemModifiers, respectively. (Note how those two symbols are blue when you copy your code into a notebook, suggesting the kernel doesn't know about those symbols, meaning they will be created in the paclet context instead of the correct one when you execute your code from within a paclet) – Lukas Lang Jan 22 '20 at 19:55