asleep
asleep
- Subject: asleep
- From: Robert Poland <email@hidden>
- Date: Mon, 22 Sep 2003 10:20:02 -0600
Hi,
Has anyone discovered a way to wake the computer yet. After much
effort I'm convinced that GUI scripting doesn't work well if the
computer is asleep.
In the following script "System preferences" opens, but the script
fails at the first GUI command.
-- WBDate&Time
set volume 2
set newApp to "System Preferences"
tell application "Finder"
tell application "System Preferences" to activate
repeat until (some process whose creator type is "sprf") exists
end repeat
end tell
tell application newApp to activate
tell application "System Events"
tell process newApp
try
click menu item "AutoApod" of menu "View" of menu bar 1
delay 1
click the button "Fetch Now" of window "AutoAPOD"
delay 3
click the button "Set As Desktop" of window "AutoAPOD"
delay 3
end try
click menu item "Date & Time" of menu "View" of menu bar 1
delay 1
tell window "Date & Time"
delay 1
tell tab group 1
click the radio button "Network Time"
delay 3
tell group 1
if the value of check box 1 is not 1 then
click check box
delay 2
end if
click button "Set Time Now"
delay 2
end tell
end tell
end tell
end tell
end tell
tell application "Finder"
tell application "System Preferences" to quit
repeat until not ((some process whose creator type is "sprf") exists)
end repeat
end tell
--
Bob Poland - Englewood, CO
http://www.ibrb.org/
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.