Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

vladimir929

macrumors newbie
Original poster
Oct 22, 2008
12
0
I am trying to write an applescript that logs into my windows machine and shuts it down (hopefully for good), but it does not seem to be recognizing my key command. My problem is that I am trying to do a control alt escape keystroke code but it does not seem to be working, I tried the another keystroke in finder just to be sure command option escape same no luck, I was wondering if someone could help me, thank you.
Problem code:
key down option
key down control
key down escape key
key up option
key up control
key up escape key

tell application "Screen Sharing" to activate
delay 1
tell application "System Events"
tell process "Screen Sharing"
keystroke "vnc://10.0.1.196"
delay 1
keystroke return
delay 1
keystroke return
delay 0.1
key down option -- Problem
key down control -- Problem
key down escape key -- Problem
key up option
key up control
key up escape key
keystroke right arrow key
keystroke return
keystroke "s"
keystroke return
end tell
end tell
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.