Re: check a folder for folders and files
Re: check a folder for folders and files
- Subject: Re: check a folder for folders and files
- From: Andrew Oliver <email@hidden>
- Date: Thu, 10 Mar 2005 10:46:18 -0800
On 3/10/05 8:10 AM, "Jan-Bultereys" <email@hidden> wrote:
> hi applescript friends,
>
> I am looking for the syntax to do:
>
> 1 - check a folder (look at the content)
> 2 - if there are folders (in this folder) do this......
> 3 - if there are files (in this folder) do that.....
I'm suspecting you really want a little more than what you say, but here
goes:
tell application "Finder"
set topFolder to (choose folder)
if (count folders of folder topFolder) > 0 then
my doThis()
end if
if (count files in folder topFolder) > 0 then
my doThat()
end if
end tell
Andrew
:)
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden