|
|
Local network messaging using AppleScript
There are plenty of reasons why someone would want to use a script such as this instead of iChat, email, Apple Remote Desktop, etc. Not everyone has ARD. To use iChat, it needs to be running on the source and dest machines. That means I'd have to run down the the basement or into the den to launch iChat, then run back, find that machine in iChat, and finally send the message. With mail, again, you have to launch it on the dest machine and wait for the mail to come in. On some machines, this might be a week's worth of mail being downloaded just to get the one you just sent.
A script such as this is great because you only have to prepare the dest machines once (turning on Remote Apple Events), and because it's a cool little hack that a user can create on their own.
I'm improving on the original by adding the ability for it to be a 2-way chat system for those times when that would be useful. I know I'm always needing to send serial numbers, url's, etc to another machine in the house and I hate writing stuff like that on paper when it's right in front of me and I can copy and paste it.
I'd post my script, but Script Debugger is in one of its "I crashed once, so I'll just keep on crashing" moods, so I gotta reboot.
Local network messaging using AppleScript
Here's my version. I chose to ask for the machine name by text instead of buttons because I have more than 3 machines I'll use this with. I also see nothing wrong with storing passwords in scripts that will only be used on my home machines. Besides, when I didn't have the username and password in the script, and I chose to store it in the keychain when it asked, it caused Script Debugger to crash during that run of the script and every time after that until I deleted that entry from my keychain.
Notice that the scripts finds the frontmost app on the remote machine instead of forcing it to the Finder. The weird thing is that the dlog comes up while the screensaver is running. Cool. Except using the Copy to Clipboard button in the screensaver causes an error, because that app is no longer running after the display dialog exists.
Local network messaging using AppleScript
Ack. Sorry I didn't prewrap the script. I didn't know the [code] format would respect the line width.
Local network messaging using AppleScript
Just a reminder from my earlier post: there is no need to run to another machine to launch iChat/email; as I pointed out, this would actually be a legitimate use of Remote Apple Events. IOW, you want to text message your buddy on the fifth floor, but his icon in iChat shows him offline; he has previously given you blanket permission to do so, so you remotely launch iChat and log him in on his machine so that he can then accept your message. If he's not there, your AppleScript dialog would fail just as readily.
Launch iChat Remotely
Fairly trivial, really: |
SearchFrom our Sponsor...Latest Mountain Lion HintsWhat's New:HintsNo new hintsComments last 2 daysLinks last 2 weeksNo recent new linksWhat's New in the Forums?
Hints by TopicNews from Macworld
From Our Sponsors |
|
Copyright © 2014 IDG Consumer & SMB (Privacy Policy) Contact Us All trademarks and copyrights on this page are owned by their respective owners. |
Visit other IDG sites: |
|
|
|
Created this page in 0.14 seconds |
|