Donnovan 0 Posted June 9, 2011 (edited) Hí! I want to show in a MsgBox a value i get form a cell in Excel. I start AutoIt with the Excel cursor in this cell. The code bellow do not work because the message box show a null valor: Dim $answer = 0 ClipPut("") WinActivate("[CLASS:XLMAIN]") send("^c") $answer = MsgBox(1,"",Clipget()) If i add a Sleep, it works, the MsgBox show the cell value: Dim $answer = 0 ClipPut("") WinActivate("[CLASS:XLMAIN]") send("^c") Sleep(30) $answer = MsgBox(1,"",Clipget()) The "^c" command take some time to conclude, and in parallel the Autoit code continues running, causing severe problems on my script. There is any way to copy values other than "Send("^c")" and then "Sleep(30)"? A way that stop the code until the value get copyed? Thankyou! Edited June 9, 2011 by Donnovan Share this post Link to post Share on other sites
MrMitchell 16 Posted June 9, 2011 Look up Excel Management in the AutoIt Help File. To get you started, you can use _ExcelBookOpen() or _ExcelBookAttach() then _ExcelReadCell(). Suggest you read up on it a bit before digging in! Share this post Link to post Share on other sites
Donnovan 0 Posted June 14, 2011 Thanks a lot! _IE... and _Excel... functions made a 1000% upgrade on my code!!! Faster, No Syncronism errors, and i can work while the script runs! Share this post Link to post Share on other sites