• 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
Select all in container window (Finder Os 9)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Select all in container window (Finder Os 9)


  • Subject: Select all in container window (Finder Os 9)
  • From: Christopher MJ Tangora <email@hidden>
  • Date: Thu, 6 Nov 2003 12:56:54 -0500

Hello,


I am writing a script to open a folder, set it to expanded list view, then select all the files in the window and change the comment field to nothing. I have gotten it to work, except for the part about selecting the entire container window. I tried recording a similar action (select all and then label everything), but when I used that command, it only selects the items in the original folder.


Can someone show me how to select the entire contents of the container window?

thanks...


code:

--this runs if the icon is double-clicked
on run
set badfolder to choose folder with prompt "Choose a folder with bad picture files"
clearcomment(badfolder)
end run

--this runs if a file is dropped on the icon
on open openedfolder
set badfolder to openedfolder as alias
clearcomment(badfolder)
end open


on clearcomment(badfolder)
tell application "Finder"
activate
set basefolder to name of badfolder as string
open badfolder
count (folders of window basefolder)
set NumberOfFolders to result
if NumberOfFolders > 0 then
repeat with i from 1 to NumberOfFolders

set current view of container window of badfolder to name
select folder i of folder badfolder
set completely expanded of selection to true

end repeat

end if
select every item of container window of folder basefolder
delay 2
set comment of selection to ""

--display completion dialog
beep
display dialog "Comments Cleared" with icon note giving up after 2
end tell
end clearcomment





thanks again




Chris Tangora

Desktop Specialist
Production Services
Daytona Beach News-Journal Corporation
Daytona Beach, Florida
_______________________________________________
applescript-users mailing list | email@hidden
Help/Unsubscribe/Archives: http://www.lists.apple.com/mailman/listinfo/applescript-users
Do not post admin requests to the list. They will be ignored.

  • Prev by Date: Re: Turning Expose on and off
  • Next by Date: Save Copy as Hinted
  • Previous by thread: Re: Turning Expose on and off
  • Next by thread: Save Copy as Hinted
  • Index(es):
    • Date
    • Thread