• 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: Sort an alias list by date - but result = alias list?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Sort an alias list by date - but result = alias list?


  • Subject: Re: Sort an alias list by date - but result = alias list?
  • From: Paul Berkowitz <email@hidden>
  • Date: Mon, 13 Nov 2000 17:31:00 -0800

On 11/13/00 2:00 PM, "cris" <email@hidden> wrote:

> How can i sort an alias list by date?
>
> {alias "Mac HD:file 1", alias "Mac HD:file 2", alias "Mac HD:file 3"}
>
> I can do it via the Finders sort function, but the result is a list of
> Finder file references which are much too slow if i work with this list
> later (because the Finder is every time involved when such a reference is
> used).
>
> Is there any other possibility to sort an alias list by date in a way that
> the result is still an alias list (a pure path list would be also fine)?


Akua Sweets (two different commands):

set fl to {alias "Mac HD:file 1", alias "Mac HD:file 2", alias "Mac
HD:file 3"}
set ls to {}
repeat with i from 1 to (count ls)
set theFile to item i of fl
set end of ls to {modification date of (basic info for theFile),
theFile}
end repeat
set ls to order list ls --sorts by mod date
set dl tp {}
repeat with j from 1 to (count ls)
set end of dl to item 2 of item j of ls
end repeat
dl

----

(or use 'creation date')



--
Paul Berkowitz


References: 
 >Sort an alias list by date - but result = alias list? (From: cris <email@hidden>)

  • Prev by Date: Re: attach folder action to trash
  • Next by Date: Re: Scripter (The Program)
  • Previous by thread: Sort an alias list by date - but result = alias list?
  • Next by thread: Re:Getting the labels of a record
  • Index(es):
    • Date
    • Thread