Select ScanSnap Profile Macro (v9.1)
Select a ScanSnap profile using the keyboard
ScanSnap's menu of profiles is super finicky, but this seems to be working reliably with limited testing using ScanSnap v. 7.0 on Big Sur. The only glitch I've found so far is the profile menu sometimes appears only for an instant then disappears, but I also have this behavior when manually clicking the ScanSnap icon.
repeat while to "timeout" the script when the profile menu is no longer open. I'm no AppleScript expert, so there may be a better way to deal with a window that doesn't want to be scripted.
The macro has one action that runs this AppleScript:
tell application "System Events" tell application process "Dock" tell list 1 tell UI element "ScanSnap Manager" -- click ScanSnap Manager on the dock and arrow down to highlight first profile perform action "AXPress" key code 125 end tell end tell end tell -- Wait for user to make selection from list repeat while (exists window 1 of application process "ScanSnap Manager") delay 0.1 end repeat end tell
Select ScanSnap Profile.kmmacros (2.0 KB)