• 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: Convert first char to lower case
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Convert first char to lower case


  • Subject: Re: Convert first char to lower case
  • From: Arthur J Knapp <email@hidden>
  • Date: Wed, 09 Jan 2002 10:20:51 -0500

> Subject: Re: Convert first char to lower case
> Date: Wed, 9 Jan 2002 12:55:34 +0000
> From: Nigel Garvey <email@hidden>

> has wrote on Wed, 9 Jan 2002 00:24:19 +0000:

>> Nigel Garvey wrote:

>>> The tests also show that if you run the test script too many times,
>>> Script Editor crashes.

>> OK, so what I've worked out is that there is a problem with lines like the
>> following:
>>
>>> set AppleScript's text item delimiters to {character 1 of Variable1}

>> Try this and see if it makes a difference:
>>
>> character 1 of Variable1
>> set AppleScript's text item delimiters to result

> Ah yes. That does seem to make it more stable. It looks like another
> manifestation of the ol' "reference in a list in a line of the script"
> problem. The tids were getting set to {character 1 of Variable1} rather
> than to {"T"}. The reference inside the list has to be resolved first by
> creating the list with a separate instruction.

I've had tremendous success with using "item X of STRING" over
"character X of STRING". This syntax also seems to be slightly
faster in exhustive speed tests.

(Perhaps when Unicode is more properly integrated into AppleScript,
"item" and "character" will no longer be interchangeable???)



> Maybe not so much a bug as a surprise.

You've described AppleScript itself... ;-)



{ Arthur J. Knapp, of <http://www.STELLARViSIONs.com>
<mailto:email@hidden>
try
<http://homepage.mac.com/ewalet/DeskTop.html>
on error number -128
end try
}


  • Follow-Ups:
    • Re: Convert first char to lower case
      • From: email@hidden (Michael Sullivan)
  • Prev by Date: RE: Version of Illustrator 9.0x docs?
  • Next by Date: Re: Convert first char to lower case
  • Previous by thread: Re: Convert first char to lower case
  • Next by thread: Re: Convert first char to lower case
  • Index(es):
    • Date
    • Thread