• 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: Odd File Write Issue
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Odd File Write Issue


  • Subject: Re: Odd File Write Issue
  • From: andy knasinski <email@hidden>
  • Date: Sun, 6 Dec 2009 19:04:32 -0600

Thanks for the tip. My string was just a plain string (I believe) and not unicode text.

The dictionary entry, below, didn't provide much help. I always assumed if you wrote a string it was as text. I will adjust to try UTF8.

[as type class] : how to write the data: as text, data, list, etc.


On Dec 6, 2009, at 7:06 AM, email@hidden wrote:


Well-known issue, andy. At some point (maybe that was Tiger), "write
this_data to the open_target_file" would (provided this_data is
Uniocde, which is very frequent, many apps talk Unicode) make a UTF-16
file (it used to produce Macintosh-encoded files before). UTF-16 is a
Unicode file format where our character set is rendered on two bytes,
one of them being 0.

I think that, to make Macintosh encoded files, you have to say
"write ... as string" and to make UTF-8 files (where our character set
is rendered mostly like ISO-8859) you says as «class utf8».

Maybe that's documented in the "write" entry in Standard Additions'
AppleScript dictionary.


_______________________________________________
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: Odd File Write Issue
      • From: Christopher Nebel <email@hidden>
  • Prev by Date: Re: Is it possible to multi-thread do shell script?
  • Next by Date: Re: Is it possible to multi-thread do shell script?
  • Previous by thread: Re: Odd File Write Issue
  • Next by thread: Re: Odd File Write Issue
  • Index(es):
    • Date
    • Thread