• 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
file path problem
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

file path problem


  • Subject: file path problem
  • From: Jean-Christophe Helary <email@hidden>
  • Date: Thu, 30 Jun 2011 17:36:51 +0900

I have a script that bumps on this:

	tell application "Mail"
		set job to item 1 of (get selection)
		set job_info to (get source of job)
		set job_name to ((get subject of job as text) & ".eml")
		set job_path to open for access file ((project_folders as text) & "informations:" & job_name) with write permission
		write job_info to job_path
		close access job_path

The problem is that, when I use that script on a reply (ie a mail that has a ":" in the subject). The script ends with an error:

File file Macintosh HD:...:...:...:(part of the subject before":"):(part of the subject after":").eml was not found.

My idea is that the ":" in the reply is considered as a folder separator when put into the path and I'd like to avoid that obviously.

Is there a way to fix that ?


Jean-Christophe Helary
----------------------------------------
fun: http://mac4translators.blogspot.com
work: http://www.doublet.jp (ja/en > fr)
tweets: http://twitter.com/brandelune

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Follow-Ups:
    • Re: file path problem
      • From: Christopher Stone <email@hidden>
    • Re: file path problem
      • From: Michelle Steiner <email@hidden>
    • Re: file path problem
      • From: Axel Luttgens <email@hidden>
  • Prev by Date: Help with retrieving messages from GMail account in Mail.app
  • Next by Date: Re: file path problem
  • Previous by thread: Re: Help with retrieving messages from GMail account in Mail.app
  • Next by thread: Re: file path problem
  • Index(es):
    • Date
    • Thread