excel vba shortcut keys code example Example: excel vba assign shortcut key to button myButton.Accelerator = "C" ' ALT+C will raise a Click event