6 Replies Latest reply: Dec 9, 2010 6:17 AM by aRKay
aRKay Level 2 Level 2
This posting is for Terence Devlin because his email address is not available. I really
appreciated your postings on how to create a Services option to send iPhotos to
Apple Mail and this got me started on using the Automator.

I have a very simple AppleScript that I need to use all the time to clear the clipboard
and I would like to have it show up under the Services menu using Automator.

The simple AppleScript is

tell application "System Events" to set the clipboard to ""

For reasons I don't understand my OS X sometimes fails to clear the clipboard after
a paste action. You cannot add a new item until the old item is cleared

Apple used to have a Finder Clear Clipboard command but is became history.

Can this easy AppleScrip be converted to Automator format?

 24" iMac and 13" MacBook Pro both w/4GB , Mac OS X (10.6.4)
Reply by Terence Devlin on Dec 8, 2010 6:48 AM Helpful
Well I'm no expert on Automator, but when you launch automator, opt to make a Service. Then in the Left Most Pane choose Utilities, and from there choose Run Apple Script. Should be straightforward from there.

But why do you need to clear the clipboard? Surely copying something new to the cipboard overwrites what was there?

Regards

TD

All replies

  • Terence Devlin Level 10 Level 10
    expertise.ilife
    iLife
    Well I'm no expert on Automator, but when you launch automator, opt to make a Service. Then in the Left Most Pane choose Utilities, and from there choose Run Apple Script. Should be straightforward from there.

    But why do you need to clear the clipboard? Surely copying something new to the cipboard overwrites what was there?

    Regards

    TD
  • aRKay Level 2 Level 2
    Thank you for the prompt response. I have it working

    Message was edited by: aRKay
  • aRKay Level 2 Level 2
    But why do you need to clear the clipboard? Surely copying something
    new to the cipboard overwrites what was there?


    I agree that something new should overwrite the clipboard but sometimes
    mine does not clear on paste. It something is on the clipboard, you cannot
    write to the clipboard. Apple used to have a menu item in the Finder to
    clear the Clipboard and it is no longer there.

    Thank you again.

    BTW, I changed the name of your Send via Mail to Send iPhoto via Mail because
    my wife was trying use it from Safari to send a picture to someone.
  • Terence Devlin Level 10 Level 10
    expertise.ilife
    iLife
    The clipboard never clears +on paste+. Copying something new overwrites the clipboard contents. To remove something from the clipboard, copy something else.

    Regards

    TD
  • aRKay Level 2 Level 2
    Copying something new overwrites the clipboard contents. To remove something from the clipboard, copy something else.


    Mine get constipated from time to time and that is why I wanted the Clear Clipboard Services item. Thanks to your help it works perfect. I don't understand why mine does not always overwrite the
    last item but the Clear Clipboard solves the problem.
  • aRKay Level 2 Level 2
    TD solved my problem and this posting is to mark the question answered