Jump to content

Marvel

Members
  • Posts

    3
  • Joined

  • Last visited

Marvel's Achievements

Seeker

Seeker (1/7)

0

Reputation

  1. Yeah, this works well. Thank you for fast replay!
  2. Hello, I was looking around forum but unfortunately I didn't found any examples how to make sleep value displayed on the gui or msgbox. example: Sleep(Random(10000,17000,1)) Does anyone know how to get value of random sleep in gui or msgbox?
  3. Hello, I'm new to AutoIT forum, i've done re-search before but still couldn't find any examples which would suit for my small project. As I mention i'm new to AutoIT forum, so obviously i'm rookie at autoit it self. At the moment i'm trying to create small project for my needs. What i want to create? Well basically autoit project which opens url from config/txt file with sequence order example first yahoo.com, after google.com so on. In config/txt file will be around 50 urls. I want to merge 2 projects into 1 with some adjustments. Part 1. Local $oIE = _IECreateEmbedded() GUICreate("MyProject", 800, 480, "250", "150", $WS_EX_MDICHILD ) GUICtrlCreateObj($oIE, 1, 1, 800, 480) GUISetState(@SW_SHOW) $oIE.Navigate("https://www.yahoo.com/") _IELoadWait($oIE) Sleep(5000) $oObject = _IEGetObjById($oIE, "nav-mail") _IEAction($oObject, "click") Sleep(8000) GUIDelete() This part working fine, this opens yahoo.com and after clicking email button. Part 2. #include <file.au3> Dim $aSite If Not _FileReadToArray("Sites.txt",$aSite) Then MsgBox(4096,"Error", " Error reading file to Array error:" & @error) Exit EndIf $x = Random(1, $aSite[0], 1) ShellExecute($aSite[$x]) Part 2 working fine too, but not like i want. This reading url from Sites.txt and starts default browser with one of them randomly. I want to make it not random but from top to bottom sequence. And also to use for every url. $oObject = _IEGetObjById($oIE, "nav-mail") _IEAction($oObject, "click") I could do in easier way (in worst case) by adding 1 by 1 urls without config/txt file, but then script would be long. Could anyone with higher autoit experience advise me how to get working both parts into one ? Best regards Marius
×
×
  • Create New...