count of Finder windows: Is this a bug?
count of Finder windows: Is this a bug?
- Subject: count of Finder windows: Is this a bug?
- From: Gil Dawson <email@hidden>
- Date: Thu, 18 Nov 2010 12:04:13 -0800
Thanks to Jim Matthews of FetchSoftWorks for helping me isolate this one.
This script:
tell application "Finder" log "count of Finder windows=" & (count of Finder windows) repeat with w in Finder windows log "name of w=" & name of w end repeat
Produces nonsense in the log:
(*count of Finder windows=3*) (*name of w=ASEDitor Recordings.scptFourth & Pyratania.png*) (*name of w=BU G3 15GBAppleScript Editor.appGalveston5Nov2010 1.png*) (*name of w=BU MBProHD 306GBBackUpAndReplaceSection.scptVegasRodeo.JPG*) (*name of w=MBProHDBlanken->iCalMCCVin.appTehachapi Loop*) (*name of w=Scratch 120Old stuffWaveland.png*) "Can’t make name of item 6 of every «class brow» of application \"Finder\" into type Unicode text." number -1700 from name of item 6 of every «class brow» to Unicode text
1) It's the names of a scrambled list of some items, but not windows. 2) Item 6? There are only 3 Finder windows open. (*count of Finder windows=3*)
tell application "Finder" log "count of Finder windows=" & (count of Finder windows) set fws to Finder windows repeat with w in fws log "name of w=" & name of w end repeat end tell
Produces what I expected:
count of Finder windows=3
So, is this a bug or some nuance of syntax that I have missed?
--Gil
|
_______________________________________________
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