• 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
Where is Trash Folder(?)?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Where is Trash Folder(?)?


  • Subject: Where is Trash Folder(?)?
  • From: Robert Poland <email@hidden>
  • Date: Sat, 26 Sep 2015 11:34:11 -0600
  • Z-usanet-msgid: XID439TiZRIm0704X33

Hi,

I’m trying to create a script, below, that I can add to a Keyboard Maestro shortcut. This script works with normal folders but “Trash” doesn’t seem to have a home.

Any thoughts/suggestions?

(* openTrashContainer - 9/26/15 - By R L Poland
*)

tell application "Finder"
	activate
	set TrashFolder to (path to Trash folder)
	set windowList to name of Finder windows as text
	# display dialog windowList
	if windowList contains "Trash" then
		close window "Trash"
	else
		open folder TrashFolder
	end if
end tell

TIA,

Robert Poland
iMac, Late 2013, 14,2
  3.2 GHz Intel Core I5, 27”
  16 GB Ram, 1TB Fusion HD
  OS X 10.10.5

 _______________________________________________
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: Where is Trash Folder(?)?
      • From: Oakman <email@hidden>
    • Re: Where is Trash Folder(?)?
      • From: Christopher Stone <email@hidden>
    • Re: Where is Trash Folder(?)?
      • From: Yvan KOENIG <email@hidden>
  • Prev by Date: Re: tags manipulation
  • Next by Date: Re: Where is Trash Folder(?)?
  • Previous by thread: Make New Rule Condition with AppleScript and Access it Via System Events
  • Next by thread: Re: Where is Trash Folder(?)?
  • Index(es):
    • Date
    • Thread