Re: Type Text(Sigma) question - Scripting non-Scriptable Apps
Re: Type Text(Sigma) question - Scripting non-Scriptable Apps
- Subject: Re: Type Text(Sigma) question - Scripting non-Scriptable Apps
- From: "Christopher C. Stone" <email@hidden>
- Date: Thu, 1 Feb 2001 01:57:05 -0600
At 10:08 -0500 01/31/2001, Xandra Lee wrote:
>
The following works fine when saved as an applet (either dbl-clicked in
>
Finder, or called by Quickeys) :
>
>
tell application "Scripter." to activate
>
type text "a" holding down command
>
type text "c" holding down command
___________________________________________________________________________
Hello Xandra,
This compiles and works fine for me (TE+ 4.0.3):
tell application "Tex-Edit"
activate
type text "a" holding down command
type text "c" holding down command
end tell
I wonder why you'd want to do such a thing in TE+ though, when you can just get the contents of the front doc:
tell application "Tex-Edit"
if exists of front document then
activate
set t to contents of front document
set the clipboard to t -- if you really need the text on the clipboard
else
say "Whoops!!!"
end if
end tell
The only reason for activating TE is because I've put the set clipboard within it's tell block.
Best Regards,
Christopher Stone
______________________________
StoneWorks Computer Consulting
email@hidden