Re: How to get the number of items in a selected Folder ?
Re: How to get the number of items in a selected Folder ?
- Subject: Re: How to get the number of items in a selected Folder ?
- From: Shane Stanley <email@hidden>
- Date: Fri, 27 Nov 2015 10:12:05 +1100
On 27 Nov 2015, at 6:47 AM, Yvan KOENIG <email@hidden> wrote:
>
> I made an other attempt with timeout of 5 * 60 * 60 seconds - but without the as alias list coercion.
> At the end of the 5th hour I got
>
> error "Erreur dans Finder : Délai dépassé pour un AppleEvent." number -1712
>
> Too bad. I will have an other reason to work without speaking to the Finder.
The sad thing is that we really should be able to recommend the Finder.
I can understand a sense of pining for the almost glory days of AppleScript, when (some) people made an effort to implement the right syntax. But the truth is that this is another problem that could be fixed by an engineer literally in minutes. Heck, one line of ASObjC *without BridgePlus* can do it.
But that's not the world we live in. El Capitan is the 12th major version of the OS to be released with the same items listed in the Finder's AS dictionary as "(NOT AVAILABLE YET)". Clearly, nobody on the Finder team cares.
Now there's an argument that ASObjC code lacks the simplicity of "pure" AppleScript and clever AppleScripty terms like "entire contents", and that's true. It is more complicated, and I understand the sentiment. Most scripters aren't programmers, and most don't particularly want to be. But telling people to use code that doesn't work, or is slow to the point of broken under typical situations, just to keep things "simple", is, I think, ultimately doing them a disservice. Moreover, when the "simple" has catches -- how many times have we seen people getting into trouble because they've passed Finder references to other applications? -- I suspect sometimes we risk veering into a nostalgia for a simplicity that never really was.
--
Shane Stanley <email@hidden>
<www.macosxautomation.com/applescript/apps/>
_______________________________________________
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