Jump to content
GamerChase

Applescript Translation Troubles

Recommended Posts

I've got a couple things I'm trying to accomplish, and Applescript is the only way I've found out how to do it. Unfortunately, it apparently doesn't translate into the languages Alfred uses, so I need an interpreter.  :unsure:

 

This is what I want it to do with a hotkey:

 

on run {input, parameters}

 

    tell application "System Events"


        keystroke "SAMPLE_TEXT"


        keystroke tab


        keystroke "SAMPLE_TEXT"


        keystroke return


    end tell   


    return input


end run

 

Any and all help would be greatly appreciated!

Share this post


Link to post

I've got a couple things I'm trying to accomplish, and Applescript is the only way I've found out how to do it. Unfortunately, it apparently doesn't translate into the languages Alfred uses, so I need an interpreter.  :unsure:

 

This is what I want it to do with a hotkey:

 

 

Any and all help would be greatly appreciated!

Did you try a 'Actions > Run NSAppleScript' object, or a 'Actions > Run Script' with the language set to 'osascript'? For the NSAppleScript, I think you need to wrap your code in 'on alfred_script q … end alfred_script' instead of 'on run … end run'

Share this post


Link to post

Did you try a 'Actions > Run NSAppleScript' object, or a 'Actions > Run Script' with the language set to 'osascript'? For the NSAppleScript, I think you need to wrap your code in 'on alfred_script q … end alfred_script' instead of 'on run … end run'

 

BEAUTIFUL!!  :D  Thanks!

 

Share this post


Link to post

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...