• 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
Re: Please delete, but don't open !
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Please delete, but don't open !


  • Subject: Re: Please delete, but don't open !
  • From: Michelle Steiner <email@hidden>
  • Date: Tue, 4 Feb 2003 09:54:03 -0700

On Tuesday, February 4, 2003, at 08:56 AM, Bernard Azancot wrote:

Under MacOSX, the following code opens the specified folder.
Is it possible to select it *without* opening ?

set theFolder to "IBM 01:Applications:Vuescan:Raw files :"
select (every file of folder theFolder)
delete selection

Are you trying to delete the folder or its contents? Your script is deleting the contents, not the folder. And when you select an item in the Finder, you have to open the containing folder.

Regardless, you do not have to select anything to delete it.

If you're trying to delete just the contents, this should work:

set theFolder to "IBM 01:Applications:Vuescan:Raw files :"
delete (every file of folder theFolder)

If you're trying to delete the folder, this should work:

set theFolder to "IBM 01:Applications:Vuescan:Raw files :"
delete theFolder

Of course, you could eliminate the variable and do everything in one line.

--Michelle

--
"There's some good in the world, Mr. Frodo, and it's worth fighting for."
_______________________________________________
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.
References: 
 >Please delete, but don't open ! (From: Bernard Azancot <email@hidden>)

  • Prev by Date: Re: Please delete, but don't open !
  • Next by Date: Re: scriptable mp3 encoder?
  • Previous by thread: Re: Please delete, but don't open !
  • Next by thread: Printing to PDF via GUI scripting.
  • Index(es):
    • Date
    • Thread