Wednesday, February 22, 2017

#1 2016-05-17 05:18:54 am

paulodzi
Member
Registered: 2016-05-17
Posts: 1

Automator taking forever

Hi

I've been using Automator for very simple task: copy and url from an Excel file, open on Chrome and save the file. So I created a script which repeats a couple of shortcuts, such as Cmd + V, Cmd + C.

I don't know why, but this runs very well at some moments, but there are moments where it takes many seconds between one action and another, when was supposed to just take 1.

How can I fix it? Do you think that because I'm using "delay" between one action and another it may increasing the time? Os is there something wrong in using "repeat"? Below you can see the initial part of the code:

repeat 10 times

tell application "Microsoft Excel"

activate

delay 1

tell application "System Events" to key code 125

delay 1

tell application "System Events" to keystroke "c" using {command down}

delay 1

end tell


tell application "Google Chrome"

activate

delay 1


tell application "System Events" to keystroke "t" using {command down}

delay 1

tell application "System Events" to keystroke "v" using {command down}

delay 1

tell application "System Events" to keystrokereturn

delay 1

end tell


end repeat


Thank you!


Filed under: Automator, slow

Offline

 

Board footer

Powered by FluxBB

[ Generated in 0.035 seconds, 11 queries executed ]

RSS (new topics) RSS (active topics)