• 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: counting files
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: counting files


  • Subject: Re: counting files
  • From: "Marc K. Myers" <email@hidden>
  • Date: Tue, 16 Jul 2002 17:55:01 -0400
  • Organization: [very little]

Duane wrote:
> I am trying to get the result of the count of the number of
> files in a folder
>
> set the source_folder to alias "WisdomQuesteLibrary:AllwestScans:" set
> the file_count to the count of the source_folder each file if file_count
> is 1 then beep else something else
>
> I get a Finder expected a reference error
>
> "count of the source_folder each file"

This worked fine for me:

set the source_folder to alias "Graphics:Daily Pictures :Pictures 20020107:"
tell application "Finder" to set the file_count to the count of the
source_folder each file
if file_count is 1 then
beep
else
beep 2
end if

Marc K. Myers <email@hidden>
http://AppleScriptsToGo.com
4020 W.220th St.
Fairview Park, OH 44126
(440) 331-1074

[7/16/02 5:54:37 PM]
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: referencing the last item in a list
  • Next by Date: Re: Creating property for 'tell application ...'
  • Previous by thread: counting files
  • Next by thread: Creating property for 'tell application ...'
  • Index(es):
    • Date
    • Thread