• 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: working with records
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: working with records


  • Subject: Re: working with records
  • From: Wayne Melrose <email@hidden>
  • Date: Thu, 23 Aug 2007 16:59:06 +0200


On 23/08/2007, at 4:52 PM, Mark J. Reed wrote:

That should be:

                    if its username is "wayne" then

note "its".

Incidentally, if I were writing this myself, I would dispense with the
individual variables and just use a record all the way through:

if its username is "wayne" then
    set foundRecord to it
end

Then later:

   tell foundRecord
        ... do stuff with "its username", "its emailadd", etc in here.
   end tell

I think that's short enough without making a bunch of variables.  But
that's just me. :)


Essentially this is what I'm doing now.. and ahh.. it's a long story..

The records and their values are used over and over, and there are lots.. so what I actually want to do is change the structure of the script (eventually) it's a big project and it's not all mine, so i have to co-operate :)

When concating a string from values in these records, it gets messy, which is why I make variables of them first, then deal with them..

Short version, after messing with it for a few days, I tend to agree with what you are saying, it's actually cleaner dealing with the records, and that's what I've settled on doing for now.

Thanks to everyone for the input..

wayne melrose
_______________________________________________
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: 
 >working with records (From: Wayne Melrose <email@hidden>)
 >Re: working with records (From: Christopher Nebel <email@hidden>)
 >Re: working with records (From: Wayne Melrose <email@hidden>)
 >Re: working with records (From: "Mark J. Reed" <email@hidden>)
 >Re: working with records (From: "Mark J. Reed" <email@hidden>)

  • Prev by Date: Re: working with records
  • Next by Date: it's late in the afternoon.. but
  • Previous by thread: Re: working with records
  • Next by thread: FTP and Applescript
  • Index(es):
    • Date
    • Thread