Sometimes you come accross a dialog box in a Mac app that can be answered by typing a letter, e.g. in Logic Pro there are dialog boxes containing a button named "Delete". If you press "d" the dialog closes and the selected part is deleted. How do they do it? I'm trying to create such a dialog box with two buttons saying "Uit" and "Aan". Pressing "u" or "a" should trigger the action. Thank you!

  • What version of macOS are you running? Are you using basic vanilla AppleScript and the display dialog command? If yes, then you are out of luck as display dialog presents a modal dialog that only responds to mouse clicks or the enter key , and tabbing_and the _space bar if [√] Use keyboard navigation to move focus between controls is checked in: System Preferences > Keyboard > Shortcuts Dec 3 '21 at 19:23
  • Hi, I'm on High Sierra, 10.13.6. Thank you for your help.
    – Jules
    Dec 3 '21 at 19:38

You must log in to answer this question.

Browse other questions tagged .