Enable Apple's Built In VNC Server


/ Published in: AppleScript
Save to your folder(s)



Copy this code and paste it in your HTML
  1. on enable_vnc()
  2. tell application "System Preferences"
  3. reveal pane "Sharing"
  4. activate
  5. end tell
  6.  
  7. tell application "System Events"
  8. tell process "System Preferences"
  9. set screen_sharing_toggle to checkbox 1 of row 2 of table 1 of scroll area 1 of group 1 of window 1
  10.  
  11. if not value of screen_sharing_toggle as boolean then
  12. click screen_sharing_toggle
  13. end if
  14. end tell
  15. end tell
  16. end enable_vnc

Report this snippet


Comments

RSS Icon Subscribe to comments

You need to login to post a comment.