• 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: about the use of character id
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: about the use of character id


  • Subject: Re: about the use of character id
  • From: Christopher Stone <email@hidden>
  • Date: Tue, 02 Sep 2014 04:50:30 -0500

On Sep 02, 2014, at 04:27, emile.a.schwarz <email@hidden> wrote:
All three gaves me the same (bad) results.

Some hours and some boots later: still does not works on all three synonyms (text, string and Unicode text).
______________________________________________________________________

Hey Emile,

Don't spend hours and many boots monkeying with a problem.  If you can't get near solving it in an hour, you're better off asking questions.

Yes.  The Finder doesn't like character id.

So either pull it out of the Finder tell block or reference AppleScript as I've done below.

----------------------------------------------------
tell application "Finder"
  set i to 32
  set zeResult to ""
  set zeChar to ""
  repeat 200 times
    set zeChar to AppleScript's character id i
    set zeResult to zeResult & tab & zeChar & return
    set i to (i + 1)
  end repeat
  return zeResult
end tell
----------------------------------------------------

There's really no real point at all in having that code within a Finder tell block.

But if you feel you must you can also do something like this:

----------------------------------------------------
on charID()
set i to 32
set zeResult to ""
set zeChar to ""
repeat 200 times
set zeChar to character id i
set zeResult to zeResult & tab & zeChar & return
set i to (i + 1)
end repeat
return zeResult
end charID
----------------------------------------------------
tell application "Finder"
charID() of me
end tell
----------------------------------------------------

--
Best Regards,
Chris

 _______________________________________________
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

References: 
 >Re: about the use of character id (From: "emile.a.schwarz" <email@hidden>)

  • Prev by Date: Re: about the use of character id
  • Next by Date: Re: excel rows
  • Previous by thread: Re: about the use of character id
  • Next by thread: Re: Simple script. Simple error. Can't find it
  • Index(es):
    • Date
    • Thread