• 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: GUI TextEdit (solved)
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: GUI TextEdit (solved)


  • Subject: Re: GUI TextEdit (solved)
  • From: Laine Lee <email@hidden>
  • Date: Tue, 03 Jul 2007 15:46:51 -0500
  • Thread-topic: GUI TextEdit (solved)

On 06/2/07 3:13 AM, "Michael Ghilissen" <email@hidden> wrote:

> Thanks to Philip Aker's contribution:
>
> 1/  include delay to pace TE
> 2/ add a click on the pop up button, before selecting menu item "HTML"

>
> the following script now works:
>
> tell application "TextEdit" to activate
> tell application "System Events"
> tell application process "TextEdit"
> click menu item "Save AsŠ" of menu "File" of menu bar item "File" of menu bar
> 1 -- menu item 7
> click pop up button 1 of group 1 of sheet 1 of window 1
> delay 1
> click menu item "HTML" of menu 1 of pop up button 1 of group 1 of sheet 1 of
> window 1 -- menu item 2
> delay 1
> click button "Save" of sheet 1 of window 1 -- save file
> end tell
> end tell
>

I've watched this with thread with interest and I'm glad you solved it. I
thought I might just add that I took a slightly different approach so that I
could create a routine for saving part of a web page into a fresh one.
Granted that my solution certainly won't include all content, but for simple
text and images, it has proved fairly reliable. If you copy either just
styled text or a combination of text and images from a web page being viewed
in Safari, for example, you can run this script and you'll get a new html
file plus accompanying images on the desktop. The way it works is to let
TextEdit decide whether the source file should be created as rtf or rtfd,
then run that through textutil, which can generate the html from either.

http://lonestar.utsa.edu/llee/applescript/webpage_clippery.html

Laine Lee


 _______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden

  • Prev by Date: Re: is "use rosetta" is checked?
  • Next by Date: Re: [Sappho] New members
  • Previous by thread: Lab Color Values in Photoshop
  • Next by thread: Re: [Sappho] New members
  • Index(es):
    • Date
    • Thread