- Joined
- Jul 16, 2018
- Messages
- 1
- Reaction score
- 0
- Points
- 1
I just want to be able to press the "Delete Printer" button with a script.
This is what I have so far -
tell application "System Preferences"
activate
set current pane to pane id "com.apple.preference.printfax"
end tell
delay 2
tell application "System Events"
tell process "System Preferences"
click button 2 of window "Printers & Scanners"
return
end tell
end tell
delay 2
tell application "System Events"
tell process "System Preferences"
delay 1
tell sheet 1 of window "Printers & Scanners"
click "Delete Printer"
end tell
end tell
end tell
What am I missing?