BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 Why HotKeySet("{1}", "TogglePause") doesn't work? Link to comment Share on other sites More sharing options...
Developers Jos Posted July 11, 2018 Developers Share Posted July 11, 2018 Show the script if you want to have any support as a single statement like this doesn't tell us anything. Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 14 minutes ago, Jos said: Show the script if you want to have any support as a single statement like this doesn't tell us anything. Jos Trying to use pause/stop functions: Global $Paused, $counter = 0 HotKeySet("{1}", "TogglePause") HotKeySet("{2}", "Terminate") While 1 Sleep(3000) MouseClick("left",113,431,2,5) Sleep(1000) MouseClick("left",1897,15,1,5) WEnd Link to comment Share on other sites More sharing options...
Moonscarlet Posted July 11, 2018 Share Posted July 11, 2018 You are not using $Paused or $counter and for HotkeySet(), you need to have functions with that name (in the second parameter) to call them using the set key: Global $Paused=True , $counter = 0 HotKeySet("{1}", "TogglePause") HotKeySet("{2}", "Terminate") While 1 If Not $Paused Then ;to see if paused or not Sleep(3000) MouseClick("left",113,431,2,5) Sleep(1000) MouseClick("left",1897,15,1,5) EndIf Sleep(10) WEnd Func TogglePause() $Paused= Not $Paused;if true set to false and vice versa EndFunc Func Terminate() ;exit Exit EndFunc Link to comment Share on other sites More sharing options...
BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 (edited) >"C:\Program Files (x86)\AutoIt3\SciTE\..\au3check.exe" -q "C:\Users\bbbbbb\Desktop\Copiere email.au3" "C:\Users\bbbbbb\Desktop\Copiere email.au3"(13,5) : error: syntax error (illegal character) Send{ ~~~~^ "C:\Users\bbbbbb\Desktop\Copiere email.au3"(13,6) : error: Statement cannot be just an expression. Send{ENTER ~~~~~^ "C:\Users\bbbbbb\Desktop\Copiere email.au3"(13,12) : error: Statement cannot be just an expression. (illegal character) Send{ENTER} ~~~~~~~~~~~^ C:\Users\bbbbbb\Desktop\Copiere email.au3 - 3 error(s), 0 warning(s) >Exit code: 2 Time: 0.05356 why i see this? Took from help file. Such help, very help, much set wow. .... -.-' Edited July 11, 2018 by BogdanNicolescu Link to comment Share on other sites More sharing options...
Moonscarlet Posted July 11, 2018 Share Posted July 11, 2018 You need () and "" Send(" <Whatever keys here> ") and for "Enter", as taken from the special keys table: Send("{ENTER}") Link to comment Share on other sites More sharing options...
Developers Jos Posted July 11, 2018 Developers Share Posted July 11, 2018 (edited) 6 minutes ago, BogdanNicolescu said: Such help, very help, much set wow. .... -.-' You did not get that from the helpfile, so please stop moaning and have a second look! EDIT: I see somebody can't restrain themselves and feels the urge you force-feed it to you. Jos Edited July 11, 2018 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 Found by looking Google !NOT! by looking help file: Send("{Enter}") Link to comment Share on other sites More sharing options...
Developers Jos Posted July 11, 2018 Developers Share Posted July 11, 2018 (edited) 2 minutes ago, BogdanNicolescu said: Found by looking Google !NOT! by looking help file: Ok, for the last time: Stop your complaining about the helpfile when you can't be bothered to spend the time reading. It is really getting annoying now! Jos Edited July 11, 2018 by Jos SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 4 minutes ago, Jos said: Ok, for the last time: Stop your complaining about the helpfile when you can't be bothered to spend the time reading. It is really getting annoying now! Jos I REALLY AM READING it and I !DO! 4 REAL try to understand, but is written by someone who knows this program at the 0 and 1 level, not by someone who just got his first pc and only knows to press start button and unplug pc from the outlet (because why not?! :)) ). This is what i try to tell: there are Professors who teach people from their vision, and teachers who teach from the student vision. I like to think i am the case of the second type. Even if i am expert-GODLIKE no GOD at something, i still manage to explain in the vision of the student. Anyway .... Thanks you all for the support. Link to comment Share on other sites More sharing options...
BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 So .... basically this is what i do whit this program: While 1 Sleep(3000) <= wait MouseClick("left",226,205,1,5) <= press A Sleep(3000) <= wait Send("^c") <= copy Sleep(3000) <= wait MouseClick("left",563,1060,1,5) <= chrome Sleep(1000) <= wait MouseClick("left",283,373,1,5) <= search box Send("^v") <= paste clipboard Send("{Enter}") <= look Sleep(5000) <= wait MouseClick("left",449,409,1,5) <= first result Sleep(5000) <= wait MouseClick("left",1095,655,3,5) <= press x3 email Send("^c") <= copy Sleep(1000) <= wait MouseClick("left",16,47,1,5) <= back MouseClick("left",464,1059,1,5) <= press excel Sleep(1000) <= wait MouseClick("left",961,205,1,5) <= press J Send("^v") <= paste MouseClick("left",1902,982,1,5) <= scroll WEnd Some time tweaks and i will be fine ^^ Would have been nice if i had some type of stop ... but whelp ... you can't have them all Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted July 11, 2018 Moderators Share Posted July 11, 2018 32 minutes ago, BogdanNicolescu said: but is written by someone who knows this program at the 0 and 1 level, not by someone who just got his first pc and only knows to press start button and unplug pc from the outlet (because why not?! :)) ). This is what i try to tell: there are Professors who teach people from their vision, and teachers who teach from the student vision. No one who works with this language is a professor; but they also aren't so lazy as to simply expect someone to barf up the code for them so they don't have to do it themselves. They also don't blame the language for their not being able to comprehend how to use it; it isn't the language's fault (or the help file's, or the forum's) if you don't have what it takes to understand the very simple syntax of AutoIt. As Jos has stated in this thread and others, you seem to do nothing but complain about what you cannot figure out. If you want to receive help on this forum you need to change the attitude, actually do some reading in the help file (everyone here can tell you haven't read anything yet), and try things out on your own. People on this forum volunteer their time and expertise, but expect to see you at least put in a modicum of effort on your own. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
BogdanNicolescu Posted July 11, 2018 Author Share Posted July 11, 2018 4 hours ago, JLogan3o13 said: No one who works with this language is a professor; but they also aren't so lazy as to simply expect someone to barf up the code for them so they don't have to do it themselves. They also don't blame the language for their not being able to comprehend how to use it; it isn't the language's fault (or the help file's, .......... YES! I know. It isn't anybody's job to teach me, but if the HELP file was made for a 1'st grader, maybe i would be able to understand something. Actually i do better on HTML because of https://www.w3schools.com/htmL/ where they teach you how to fly a boeing 787 whit basic stuff and they explain why and where and how. Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted July 11, 2018 Moderators Share Posted July 11, 2018 14 minutes ago, BogdanNicolescu said: but if the HELP file was made for a 1'st grader, maybe i would be able to understand something. I reiterate, that sounds like a personal issue. You are complaining about the language and the help file, when the issue seems to be your level of comprehension. The help file is written in such a way that the majority of reasonably intelligent adults can easily understand it - sorry if that does not suffice for your situation. "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum! Link to comment Share on other sites More sharing options...
Developers Jos Posted July 11, 2018 Developers Share Posted July 11, 2018 (edited) I am done with your moaning about the helpfile. It is not a learn but rather a reference/syntax document, but very complete for a freeware language with loads of examples. This topic is now closed and the next time you have any smart remark about the helpfile, you will get to know my 2x4 ( and no, I am not going to explain this) Jos Edited July 11, 2018 by Jos JLogan3o13 and BogdanNicolescu 1 1 SciTE4AutoIt3 Full installer Download page - Beta files Read before posting How to post scriptsource Forum etiquette Forum Rules Live for the present, Dream of the future, Learn from the past. Link to comment Share on other sites More sharing options...
Recommended Posts