• 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: Problem with simple finder script- make new file, open for access
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Problem with simple finder script- make new file, open for access


  • Subject: Re: Problem with simple finder script- make new file, open for access
  • From: Michelle Steiner <email@hidden>
  • Date: Mon, 31 Jul 2006 16:32:12 -0700

On Jul 31, 2006, at 3:52 PM, Dan Doughtie wrote:


tell application "Finder" set MyFile to make new file at desktop with properties {name:DoStoryName(winningTeam) of me} open for access file MyFile with write permission write AGATE to file MyFile starting at eof close access file MyFile end tell

Open for access through close access should be outside the tell block.

For that matter, you don't need the tell block at all.

set MyFile to (choose file name default location (path to desktop) default name "DoStoryName(winningTeam)")
set theFile to open for access MyFile with write permission
write AGATE to theFile starting at eof
close access theFile


If you want it always at the desktop, you can hard code that instead of using "choose file name"

-- Michelle

--
My choice early in life was either to be a piano-player in a whorehouse or a politician. And to tell the truth, there's hardly any difference.
-- Harry S. Truman (circa 1962)


_______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden


References: 
 >Problem with simple finder script- make new file, open for access (From: Dan Doughtie <email@hidden>)

  • Prev by Date: Problem with simple finder script- make new file, open for access
  • Next by Date: Re: Filemaker 8.5 and current record syntax
  • Previous by thread: Problem with simple finder script- make new file, open for access
  • Next by thread: Re: Problem with simple finder script- make new file, open for access
  • Index(es):
    • Date
    • Thread