If you have never worked with AppleScript before, don’t fret. The following Mac remote control scripts are very short and easy to use.
Settings For Remote Control
In order to remotely control a Mac, say your desktop machine, you must first set it up for commands to be sent to it. To do this, launch System Preferences > Sharing on the Mac you want to control. Click the box next to Remote Apple Events, and set user restrictions if you need to.Create A Script Command
Now, on another Mac, say your laptop, launch the AppleScript Editor, which can be found in Applications Folder > Utilities Folder. Our first command will be one that puts the remote Mac to sleep.In AppleScript, go to File > New. Copy and paste the following simple script in the editor:
tell application “Finder” of machine “eppc://192.163.1.2.3″Replace the sample IP address with the address of the Mac you’re going to send the command to. Be sure the address comes after “eppc://.
sleep
end tell
Saving Your Scripts
There are a couple of ways you can save and access your scripts. You can save them to the Scripts Menu that can be put into the menu bar of your desktop. It looks like this:Other Command Scripts
Here are a few other commands that you might want to send to your Mac.Start iTunes
tell application “iTunes” of machine “eppc://IP Address”
play
end tell
Stop iTunes
tell application “iTunes” of machine “eppc://IP Address”
stop
end tell
Increase Volume
tell application “Finder” of machine “eppc://IP Address”
set volume 7 — Call this one “Full Volume”
end tell
Open The Safari Browser
tell application “Safari” of machine “eppc://IP Address”
activate
end tell
Close The Safari Browser
tell application “Safari” of machine “eppc://IP Address”Let me know if this tutorial works out for you. If you know of other AppleScript commands that our readers might find useful, please share them here. For some more AppleScript automation ideas, check out this article, and if you looking for Mac automation tips, download my free MUO Guide to Mac Automation
quit
end tell
0 comments:
Post a Comment