Submit Hint Search The Forums LinksStatsPollsHeadlinesRSS
14,000 hints and counting!

Click here to return to the '10.3: Start Internet Sharing via AppleScript' hint
The following comments are owned by whoever posted them. This site is not responsible for what they say.
10.3: Start Internet Sharing via AppleScript
Authored by: Jewtobog on May 10, '08 11:39:26PM

Posted this to an error (above) but it gets buried so posting it again at top level for someone hunting for this script and will get stumped by the original one. If your looking for a script to do this [on & off] try this:

tell application "System Preferences" to set current pane to pane ""
tell application "System Events" to tell process "System Preferences"
click checkbox 1 of row 10 of table 1 of scroll area 1 of group 1 of window "Sharing"
delay 1
if (exists sheet 1 of window "Sharing") then
click button "Start" of sheet 1 of window "Sharing"
end if
end tell
ignoring application responses
tell application "System Preferences" to quit
end ignoring

[ Reply to This | # ]
10.3: Start Internet Sharing via AppleScript
Authored by: prramesh on Nov 11, '09 08:18:25AM

In snow leopard you have to change row 10 into row 11

[ Reply to This | # ]