Cooler 0 Posted July 16, 2019 Hi Friends, I created a script, which takes number of entries from the excel sheet as count and it will run the loop according to the count value. Loop is running good. Loop limits and all it's taking fine. For example if the loop limit is $count = 50. while executing the script will automatically quit anywhere, once it crossed 30th iteration. My doubt here is, Why its happening? Is RAM size matters, or any junk memory is creating, or any thing i want to clear in starting or in between of the loop. Give some idea about this friends...! ☺️Thanks...! Share this post Link to post Share on other sites
Earthshine 518 Posted July 16, 2019 Post your script for help. How are we supposed to know what’s wrong with your script when we can’t see it? My resources are limited. You must ask the right questions Share this post Link to post Share on other sites
Cooler 0 Posted July 16, 2019 Yup sure...! expandcollapse popupFor $j = 1 To $count MouseMove(500,500) Sleep(2000) MouseClick("left",500,500) Send ("{DOWN}") Sleep(500) MouseClick($MOUSE_CLICK_RIGHT) Send ("p") Sleep(500) WinActivate("Properties") WinWaitActive ("Properties") Sleep(1000) $hndl7 = WinGetHandle("Properties") ;Writing the report in Excel Sleep(500) ;getting the required handles $Part = ControlGetText($hndl7, "", "Edit3") $Doc = ControlGetText($hndl7, "", "ComboBox2") $Docu = ControlGetText($hndl7, "", "Edit34") $Finish = ControlGetText($hndl7, "", "ComboBox24") WinClose("Properties") ;writing them into excel $eBook.Sheets(2).Select _Excel_RangeWrite ( $eBook, $eBook.Activesheet, $Part , "B"&$a ) _Excel_RangeWrite ( $eBook, $eBook.Activesheet, $Doc , "C"&$a ) _Excel_RangeWrite ( $eBook, $eBook.Activesheet, $Docu , "E"&$a ) _Excel_RangeWrite ( $eBook, $eBook.Activesheet, $Finish , "F"&$a ) ;clearing the variables used to store handles from properties $Part = "" $Doc = "" $Docu = "" $Finish = "" $a = ($a + 1) Next Share this post Link to post Share on other sites
Nine 993 Posted July 16, 2019 It is simple debugging. Put multiple ConsoleWrite to check the values of the variables. Follow the flow and you will find it by yourself. 1 Earthshine reacted to this Not much of a signature but working on it... Spoiler Block all input without UAC Save/Retrieve Images to/from Text Tool to search content in au3 files Date Range Picker Sudoku Game 2020 Overlapped Named Pipe IPC x64 Bitwise Operations Multi-keyboards HotKeySet Fast and simple WCD IPC GIF Animation (cached) Share this post Link to post Share on other sites
Cooler 0 Posted July 17, 2019 Yeah i did that bro. Its running fine for less loop count. But for loop count more than 50, it'll stop after 40th count. My RAM is less. So there mignt be chance of system program manager's speed is not match with script's running speed. Thus I kept winwait and cursor status wait. Now working fine. B n touch my friend...! Thanks! Share this post Link to post Share on other sites