How do I paste into a different app?
sarah.reichelt at gmail.com
Wed Dec 30 18:19:00 EST 2009
On Thu, Dec 31, 2009 at 8:55 AM, Bill Vlahos <bvlahos at mac.com> wrote:
> It looks like on the Mac you can get AppleScript to send keystrokes by telling the application "System Events".
> tell application "System Events"
> keystroke "x"
> end tell
> How can I tell Rev to execute this AppleScript code?
Store that script in a field or custom property, then when you need
it, put it into a variable and use "do as AppleScript".
put the cPasteAppleScript of this stack into tScript
do tScript as AppleScript
To emulate a paste command, you will need something like:
keystroke "v" using command down
However you probably want to make sure the correct app is frontmost
before you paste.
So you can use something like this as the first line of your AppleScript:
tell application "TextEdit" to activate
More information about the Use-livecode