Re: Locating A Menu Item
Re: Locating A Menu Item
- Subject: Re: Locating A Menu Item
- From: Hugo Benitez <email@hidden>
- Date: Wed, 30 Jul 2003 08:43:42 -0500
Jim,
If you are going to use Internet Connect to connect, I suggest the
following script, which opens IC, check for the connection status and,
if idle, opens connection, waits for the connection to be status 4
(conneced) and quits; otherwise, if connected, it closes the connection
and quits:
--INTERNET CONNECTION
tell application "Internet Connect"
get state of status of PPP configuration "Internal Modem" --check
status of connection
if result > 0 then --connected
disconnect
else
try
with timeout of 45 seconds --try to connect for 45 seconds,
otherwise exit with error
connect
repeat
get state of status of PPP configuration "Internal Modem"
if (result = 4) then
exit repeat
delay 5
end if
end repeat
end timeout
on error
disconnect
end try
end if
quit
end tell
Regards,
Hugo
_______________________________________________
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.