How can you lock your screen from another Macintosh?

The following applescript will allow you to lock the screen, over the network, from any other macintosh. Just keep in mind, “Remote Apple Events” will probably have to be turned on (System Preferences -> Sharing).

property ipNumber : 'Real IP address here'
property userName : 'real username here'
property pasword : 'real password entered here'
set remMachine to 'eppc://' & userName & ':' & pasword & '@' & ipNumber
tell application 'Finder' of machine remMachine to do shell script '/System/Library/CoreServices/Menu Extras/User.menu/Contents/Resources/CGSession -suspend'"

No related posts.

   
© 2011 The Matrix Data BankSuffusion theme by Sayontan Sinha