Listing contents of Spotlight comment fields in folder
Listing contents of Spotlight comment fields in folder
- Subject: Listing contents of Spotlight comment fields in folder
- From: "Ernest Schaal" <email@hidden>
- Date: Tue, 15 May 2007 05:58:50 +0900
I have been trying to develop a short strip that would create a text
file listing the name of each folder or file having a Spotlight
comment along with the content of that comment.
I have been using the scripts in the Finder Scripts folder as
examples. I note that the dictionary lists comment as a property of
finder items. This is as far as I got before getting an error.
(*
Check for comments
*)
-- get the path to the folder of the front window
-- if no windows are open, the desktop folder will be used
try
tell application "Finder" to set the source_folder to (folder of the
front window) as alias
on error -- no open folder windows
set the source_folder to path to desktop folder as alias
end try
set the item_list to list folder source_folder without invisibles
set source_folder to source_folder as string
repeat with i from 1 to number of items in the item_list
set this_item to item i of the item_list
set this_item to (source_folder & this_item) as alias
set this_comment to comment for this_item
The error message is:
Applescript Error
<<script>> doesn't understand the comment message
What is the best way to get the comment message?
_______________________________________________
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