• 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
Listing contents of Spotlight comment fields in folder
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

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
  • Follow-Ups:
    • Re: Listing contents of Spotlight comment fields in folder
      • From: Michelle Steiner <email@hidden>
    • Re: Listing contents of Spotlight comment fields in folder
      • From: James Nierodzik <email@hidden>
    • Re: Listing contents of Spotlight comment fields in folder
      • From: Philip Aker <email@hidden>
  • Prev by Date: Re: Filemaker 8.5 stored applescript problem
  • Next by Date: Re: Filemaker 8.5 stored applescript problem
  • Previous by thread: Re: Load several webpages in succession
  • Next by thread: Re: Listing contents of Spotlight comment fields in folder
  • Index(es):
    • Date
    • Thread