• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Copy image to clipboard
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Copy image to clipboard


  • Subject: Re: Copy image to clipboard
  • From: Simon Forster <email@hidden>
  • Date: Thu, 1 Apr 2004 18:40:44 +0100

Many thanks for this - much neater than opening in Safari, emulating command-c; command-w; etc. No more windows flying all over the place!

Simon Forster
_____________________________________________________
LDML Ltd, 62 Pall Mall, London, SW1Y 5HZ, UK
Tel: +44 (0)70 9230 5244 Fax: +44 (0)70 9230 5247
_____________________________________________________

On 1 Apr 2004, at 15:34, Hanaan Rosenthal wrote:

This finally takes the file (I believe any major format should work)
and puts it in the clipboard.

set imageFilePath to "path:to:image_name.gif"
set pictFilePath to "path:to:tmp.pict"
tell application "Image Events"
set theImage to open file imageFilePath
tell theImage
save as PICT in pictFilePath
end tell
end tell
set fdata to read file pictFilePath as picture from 513
set the clipboard to fdata
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.


References: 
 >Re: Copy image to clipboard (From: Hanaan Rosenthal <email@hidden>)

  • Prev by Date: Help; script doesn't work
  • Next by Date: Re: Vacation mail script - junk mail problem
  • Previous by thread: Re: Copy image to clipboard
  • Next by thread: Re: Copy image to clipboard
  • Index(es):
    • Date
    • Thread