Added a button to 'Try Again'. It's a little annoying that the alert window pops before the system preferences appear; could be improved
Bit of cleanup. Changed event tap location to see if this would work more consistently on my other Mac