MACSCRPT Archives

December 2008

MACSCRPT@LISTSERV.DARTMOUTH.EDU

Options: Use Monospaced Font
Show Text Part by Default
Show All Mail Headers

Message: [<< First] [< Prev] [Next >] [Last >>]
Topic: [<< First] [< Prev] [Next >] [Last >>]
Author: [<< First] [< Prev] [Next >] [Last >>]

Print Reply
Subject:
From:
Jon Pugh <[log in to unmask]>
Reply To:
Macintosh Scripting Systems <[log in to unmask]>
Date:
Fri, 19 Dec 2008 10:07:33 -0800
Content-Type:
text/plain
Parts/Attachments:
text/plain (19 lines)
At 12:00 PM -0600 12/19/08, john darnell wrote:
>I am trying to write a simple script to delete a file.  The script looks
>like this:
>
>set firstfile to "Macintosh HD:Users:PRG03:Library:Preferences:Suitcase
>Preferences:FontTrackingFile"
>if file firstfile exists then
>	set myresult to delete firstfile
>end if

tell application "Finder"
  set myFile to file "Macintosh HD:Users:PRG03:Library:Preferences:Suitcase Preferences:FontTrackingFile"
  delete myFile
end tell

The Finder manages files, not AppleScript itself.

Jon

ATOM RSS1 RSS2