• 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: export e-mail attachments
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: export e-mail attachments


  • Subject: Re: export e-mail attachments
  • From: Jeremy Sellors <email@hidden>
  • Date: Mon, 3 Mar 2003 10:39:15 -0800

Well that script works OK. Thanks John.
When I get to play with this a bit I have another idea, but first let me explain what I am trying to do.

E-mails come in to Mail.app with PDF, Image or .doc (Word) etc attachments used to make up an ad. I want to export this e-mail and attachments (or attachment name and path info) to a new record in a FMPro document. this can then be linked to a clients Insertion Order for reference and further processing.

Now if I import all the MIME source of the e-mail into a text field. This includes the attachment code.

Would it be possible to parse this code with an Applescript or Perl like your EXTRA STUFF piece or even using FMPro calculation to get the attachments?


On Sunday, March 2, 2003, at 11:07 AM, John Delacour wrote:

At 12:33 pm -0800 1/3/03, Jeremy Sellors wrote:

How can I save e-mail attachments in Mail.app?
I need to import selected e-mails into FileMaker Pro and save the attachment to a folder.


I see you've had no reply from the person who believes Mail to be scriptable, so while we wait for a one-liner from that quarter, here's a contorted script almost worthy of Apple that can do what you want.

Select a message having an attachment in the message viewer and run this script. The attachment will be expanded by Stuffit Expander on to your desktop. If you want to get the text of the message too, then it will need to be parsed and I haven't bothered with that bit, excet that after "EXTRA STUFF" I get the whole content of the message, which will not display if it's too big. There is also the problem that Mail at some indeterminate point changes the name of the files, so we have to try to read the final name and if that fails read the initial name. You'll need to delete the numbered mailboxes by hand, unless someone tells us otherwise, because Mail turns phantoms into reality -- and vice versa of course :-)
snip script
_______________________________________________
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.

  • Follow-Ups:
    • Re: export e-mail attachments
      • From: John Delacour <email@hidden>
  • Prev by Date: Activation by e-mail?
  • Next by Date: Re: export e-mail attachments
  • Previous by thread: Re: export e-mail attachments
  • Next by thread: Re: export e-mail attachments
  • Index(es):
    • Date
    • Thread