PDA

View Full Version : AppleScript to toggle display settings?




m021478
Mar 25, 2009, 09:53 PM
I often use Leopard's Screen Sharing capabilities via my Macbook Pro laptop to control my Mac Pro desktop computer. The problem is that my desktop computer is running a dual-monitor configuration, with a 1920x1200 primary screen, and a 2560x1600 30" Cinema Display as my secondary screen, which as you can imagine is pretty difficult to manage from the measly 1440x900 resolution of my laptop.

I was hoping that someone might be able to help me create an applescript (that can be launched with a single click from either the Dock or a Finder Window Toolbar), which I could use to enable the Display Panel option to "Mirror Displays", and then to change the resolution of my Mac Pro's screen to 1600x1000 for reasonable viewing on my Macbook Pro.

If two scripts need to be created for this to work (one to toggle display settings for remote viewing, and another to toggle them back to normal), then that would be fine, but if it's not any more or less difficult to have a single script handle both directions of the toggle, then that would of course be best...

Any help that anyone can offer here would be sincerely appreciated! Thanks so much for your time!