Mailing Lists: Apple Mailing Lists

Image of Mac OS face in stamp
 
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TextEdit Can't Find Without "as text"



On Aug 12, 2007, at 8:04 AM, Gil Dawson wrote:

Clearly the "as text" phrase in the demo script below is essential, but why?

Because "first name" returns unicode text, as do all other text properties of a person.


When you omit "as text", you are writing unicode text (i.e., two bytes per character). If you open the file in Text Wrangler, and show invisibles, you'll see that there's an upside-down question mark before each character in the line where you did not use "as text" to write it. That character represents the null character (ascii zero).

"Find" in TextEdit--and also in Text Wrangler, for that matter-- apparently can't handle Unicode text.

-- Michelle

--
If there's nothing that offends you in your community, then you know you're not living in a free society.
Kim Campbell - former Prime Minister of Canada


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

This email sent to email@hidden
References: 
 >TextEdit Can't Find Without "as text" (From: Gil Dawson <email@hidden>)



Visit the Apple Store online or at retail locations.
1-800-MY-APPLE

Contact Apple | Terms of Use | Privacy Policy

Copyright © 2007 Apple Inc. All rights reserved.