• 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: Property of a record
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Property of a record


  • Subject: Re: Property of a record
  • From: Nigel Garvey <email@hidden>
  • Date: Wed, 18 May 2011 22:21:41 +0100

Jim Brandt wrote on Tue, 17 May 2011 14:31:37 -0500:

>Thanks Nigel. That gets what I need.
>
>So, am I to expect problems with this when I move this script to
>Leopard or Snow Leopard?

I don't think so, as long as you use one of the suggestions which work
for you now. The first one's probably the best:

  set {text:RowText} to it

It's the only one which unambiguously says you want the value of 'it's
'text' property, whereas the other two return the first value of a
certain class.

In Snow Leopard (without the benefit of TextCommands), your orignal line…

  set RowText to it's text -- text of the row

… returns a _list_ of text. It's because of the ambiguity surrounding
the meaning of 'text' in this context. You have in mind a record
property labelled 'text'; the compiler assumes the reference means every
text value in the list or record.

NG

>
>On May 17, 2011, at 2:01 PM, Nigel Garvey wrote:
>
>> These work on my Tiger machine:
>>
>>   set {text:RowText} to it
>>
>>   set RowText to item 1 of (its every Unicode Text)
>>
>>   set RowText to first Unicode text of (it as list)

 _______________________________________________
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

  • Prev by Date: another why
  • Next by Date: Re[2]: Uniquely identify range in MS Excel
  • Previous by thread: Re: Property of a record
  • Next by thread: Next repeat?
  • Index(es):
    • Date
    • Thread