enter image description here

enter image description here

I've tried coding it in different ways, but no matter what I do it will not type "22.com".

  • 5
    Hi, welcome to Ask Different. Why not add this to your previous AppleScript question at: apple.stackexchange.com/questions/258415/… one of our users will likely be able to kill all of your birds in one stone instead of opening new threads. – bret7600 Oct 23 '16 at 22:50
  • 3
    If the first pic contains your real password, I recommend to change the password immediately. – klanomath Oct 23 '16 at 22:57
  • I just tried tell application "System Events" to keystroke "22.com" and it output: 22.com – user3439894 Oct 24 '16 at 0:52

I've found that trying to keystroke with a large number of characters is highly unreliable. It doesn't seem to wait for every character to be typed before returning. I'd suggest trying this workaround I've been using:

on keystroke_string_(keystr)
    tell application "System Events"
        repeat with _character in keystr
            keystroke _character
        end repeat
    end tell
end keystroke_string_

That'll iterate through the characters, and press each one manually. I've found that this works nicely with any length of string.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .