First, if there is a better forum for this post, please feel free to move it.
In trying to find a solution to a repetitive task, I found some old code by skwire, which was almost perfect. It did what I wanted but required a key combination to move to the next string in the array. I wanted to see if I could get it to run by itself.
I have a very basic understanding of it's function, and how now tweaked to to the following. The only thing I have not been able to work out is how to stop the loop when the array matches "z", which would allow for a variable length array. So for the moment I have set the loop to 3. Please note d, e, and z in the array are just placeholders for URL's.
myURLs =
(
d
e
z
)
StringSplit, myURLsArray, myURLs, `n
WinActivate, ahk_exe chrome.exe
Sleep, 3000 ;Time to move focus to Chrome
Send, +!,
Loop, 3
{
myCounter++
% ( myCounter > myURLsArray0 ) ? ( myCounter := 1 ) : ()
myURL := "myURLsArray" . myCounter
SendInput, ^l
Sleep, 750
SendInput, % %myURL%
Sleep, 1000
SendInput, {ENTER}
Sleep, 2000
SendInput, {ENTER}
Sleep, 3000
SendInput, {ENTER}
Sleep, 2000
}
If someone can guide me into what I need to do, it would be appreciated. If you wonder, the three SendInput {ENTER} are deliberate.
Regards John