Nitto Posted June 21, 2007 Share Posted June 21, 2007 Hi a newbie question i don't know a lot about of loops, i would like to have a script with a loop and hotkey, like loop if F6 key is pressed, and make the script to be active, just waitng to make the loop and have other hotkey to exit the script, thanks. Link to comment Share on other sites More sharing options...
martin Posted June 21, 2007 Share Posted June 21, 2007 (edited) Hi a newbie question i don't know a lot about of loops, i would like to have a script with a loop and hotkey, like loop if F6 key is pressed, and make the script to be active, just waitng to make the loop and have other hotkey to exit the script, thanks. #include <GUIConstants.au3> HotKeySet("{F6}","Goloopy][ÝÊBÝÙ^TÙ] ][ÝÞÑ_I][ÝË ][ÝÜÝÜ] ][ÝÊBÛØ[ ÌÍÜÝfÇ6RÂb33c¶¶VWvöærÒG'VP¤uT7&VFRb33·vFærf÷"cbb33²Ã3ð¤u%MÑMÑÑ ¤()]¡¥±9½ÐÀÌØíÍÑÉÐ($($ÀÌØí5ÍôU%Ñ5Í ¤(%%ÀÌØí5Í= $GUI_EVENT_CLOSE Then Exit WEnd WinSetTitle('waiting for F6&#ÎNË ÌÎNÉÌÎNË ÌÎNÛÝÈØZ][ÈÜIÌÎNÊBÚ[H ÌÍÚÙYÛÚ[ÂBIÌÍ´×6rÒuTvWD×6r bb33c´×6rÒb33c´uTôUdTåEô4Äõ4RFVâW@¥tVæ@ ¤gV½±½½Áä ¤($ÀÌØíÍÑÉÐôQÉÕ)¹Õ¹(()Õ¹ÍѽÁ¥Ð ¤(ÀÌØíÁ½¥¹ôlse EndFunc Edited June 21, 2007 by martin Serial port communications UDF Includes functions for binary transmission and reception.printing UDF Useful for graphs, forms, labels, reports etc.Add User Call Tips to SciTE for functions in UDFs not included with AutoIt and for your own scripts.Functions with parameters in OnEvent mode and for Hot Keys One function replaces GuiSetOnEvent, GuiCtrlSetOnEvent and HotKeySet.UDF IsConnected2 for notification of status of connected state of many urls or IPs, without slowing the script. Link to comment Share on other sites More sharing options...
ofLight Posted June 21, 2007 Share Posted June 21, 2007 HotKeySet("{F6}", "_BeginLoop" ) HotKeySet("{F7}", "_ExitLoop" ) HotKeySet("{ESC}", "_Exit" ) Global $i = 1 While 1 Sleep(25); Dont cook my CPU Wend Func _BeginLoop() $i = 1 While $i = 1 If $i = 0 Then ExitLoop Msgbox( 0,"BeginLoop", "You pressed F6", 1) Wend EndFunc Func _ExitLoop() $i = 0 EndFunc Func _Exit() Exit EndFunc Dang u beat me Martin There is always a butthead in the crowd, no matter how hard one tries to keep them out.......Volly Link to comment Share on other sites More sharing options...
Nitto Posted June 22, 2007 Author Share Posted June 22, 2007 c2--><!--CiNpbmNsdWRlICZsdDtHVUlDb25zdGFudHMuYXUzJmd0OwpIb3RLZX[ÒXÔMÙLLÖÎLÞ]ÛXÖÐBXÔMÒÔXÔ[ÒXvSe5§Es÷vÖ5gfDGG¦DsvÖ5gfDG76w$swvt¦×t×¥v35&6åu¤$uáéiMÝ)¥5Ý5édÝÉY±ÙÕ¹%Á!(ÅiEÁ!YU±µY¡U½)¥5é=QÐÍe]°ÁÕ¹%iÙ¥ 9YjMzk7LDMwMCwxKTsKR1 JU2V0U3RhdGUoKQoKV2hpbGUgTm90ICYjMDM2O3N0YXJ0CgkKCSYjMLÌ^PNRQYÕYL^YÜÙÛP[R^^ÌÂÐ[R^^[LVudvÆ&$fTvÃ6v´µcgU¤ôµc&ÇUS%cdvÃ$uVô¦×¤õGC5vÃsVäu§f6$tæ §¦³t e©5é¬Ý)¥5é=QÍÍ)¥5é=QÑÕÍÉÁ±Õiå µÍ%I©Uµ%é4Õ=å- ±½]á±% e©54É where does the script to loop goes ??????? Link to comment Share on other sites More sharing options...
ofLight Posted June 25, 2007 Share Posted June 25, 2007 Sorry Nitto, the code in the post you made apears as Gobbldy Goop to me . I think maybe its a Forum Bug ?? So I dont understand the question There is always a butthead in the crowd, no matter how hard one tries to keep them out.......Volly Link to comment Share on other sites More sharing options...
PsaltyDS Posted June 25, 2007 Share Posted June 25, 2007 Sorry Nitto, the code in the post you made apears as Gobbldy Goop to me . I think maybe its a Forum Bug ??Same here. Been like that for a few days now. I think I heard in the Chat forum that JdeB is on a motorcycle tour for a few days, so the forum fix is not going to be immediate. Valuater's AutoIt 1-2-3, Class... Is now in Session!For those who want somebody to write the script for them: RentACoder"Any technology distinguishable from magic is insufficiently advanced." -- Geek's corollary to Clarke's law Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now