• 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
Help with scripting text editor with comments from file?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Help with scripting text editor with comments from file?


  • Subject: Help with scripting text editor with comments from file?
  • From: "T.J. Mahaffey" <email@hidden>
  • Date: Tue, 06 Mar 2001 09:17:08 -0600

Can anyone tell me what I'm doing wrong here?
I'm trying to create a droplet that will perform the following on the items
dropped on it:

Create a text file, name it the same as the file's name, set the text of the
file to the text from the file's comment window, and save the file to the
HD. I'm using Tex-Edit Plus, but any insight you folks could give will apply
to most any small text editor like it.

Here's my script that's error'ing out on the 7th line where it makes the new
text document.

on open newItems
repeat with allFiles in newItems
tell application "Finder"
set itemName to name of allFiles
set myComment to ((comment of selection) as text)
tell application "Tex-Edit Plus"
make new document with properties {name:itemName,
text:myComment}
save document in file "VST 30gb:itemName" as text
close document itemName
end tell
end tell
end repeat
end open

Many thanks.
T.J. Mahaffey


  • Prev by Date: TIDs case insensitive?
  • Next by Date: help with a tcp/ip script
  • Previous by thread: Re: TIDs case insensitive?
  • Next by thread: Re: Help with scripting text editor with comments from file?
  • Index(es):
    • Date
    • Thread