• 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: TextEdit AppleScript bug
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: TextEdit AppleScript bug


  • Subject: Re: TextEdit AppleScript bug
  • From: Jeffrey Berman <email@hidden>
  • Date: Tue, 15 Oct 2002 07:45:02 -0500

On Tue, 15 Oct 2002, Bill Cheeseman <email@hidden> wrote:

> James Hober reported to me that 'close front window saving yes' no longer
> works correctly in TextEdit under Mac OS X 10.2 (Jaguar). It closes the
> window, but it doesn't save changes to the file (whether the file has been
> previously saved or not).
>
> I get the same problem. Does this work for anybody?

Bill:

I discovered the same problem, but it seems to occur only if the text in the
window has been changed through AppleScript commands.

A different response occurs if you type some text in the front window
manually and then run the "close front window saving yes" command. Then
TextEdit comes up with a dialog asking if you want to save the file.

When the changes in the file come from AppleScript commands, I found I could
also trigger the dialog asking if you want to save the file by inserting the
following command before the save:

set modified of front document to true

I was surprised this worked because the TextEdit dictionary lists the
modified property of a document as read only.

-Jeffrey Berman
_______________________________________________
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.

  • Follow-Ups:
    • Re: TextEdit AppleScript bug
      • From: Bill Cheeseman <email@hidden>
  • Prev by Date: Re: OS 9.2.1 - popup windows - scriptable?
  • Next by Date: (no subject)
  • Previous by thread: Re: Assign Categories in Cumulus
  • Next by thread: Re: TextEdit AppleScript bug
  • Index(es):
    • Date
    • Thread