nodelay Posted July 24, 2019 Share Posted July 24, 2019 hi, I need to pass a script from ahk to autoit but I am not able to achieve it. script: $F1:: While GetKeyState("F1","P") Loop { Send,{F1} MouseClick, left if not GetKeyState("F1","P") break } return If anyone can help me, I would appreciate the help Link to comment Share on other sites More sharing options...
Nine Posted July 24, 2019 Share Posted July 24, 2019 I do not know ahk and have no intent of learning it. Since this is an AutoIt forum, how about YOU learn AutoIt ! Post your code if you have trouble with it. We will then help you... “They did not know it was impossible, so they did it” ― Mark Twain Spoiler Block all input without UAC Save/Retrieve Images to/from Text Monitor Management (VCP commands) Tool to search in text (au3) files Date Range Picker Virtual Desktop Manager Sudoku Game 2020 Overlapped Named Pipe IPC HotString 2.0 - Hot keys with string x64 Bitwise Operations Multi-keyboards HotKeySet Recursive Array Display Fast and simple WCD IPC Multiple Folders Selector Printer Manager GIF Animation (cached) Screen Scraping Multi-Threading Made Easy Link to comment Share on other sites More sharing options...
water Posted July 24, 2019 Share Posted July 24, 2019 As we do not know AHK it would help if you could tell us what the goal of your AHK script is. My UDFs and Tutorials: Spoiler UDFs: Active Directory (NEW 2024-07-28 - Version 1.6.3.0) - Download - General Help & Support - Example Scripts - Wiki ExcelChart (2017-07-21 - Version 0.4.0.1) - Download - General Help & Support - Example Scripts OutlookEX (2021-11-16 - Version 1.7.0.0) - Download - General Help & Support - Example Scripts - Wiki OutlookEX_GUI (2021-04-13 - Version 1.4.0.0) - Download Outlook Tools (2019-07-22 - Version 0.6.0.0) - Download - General Help & Support - Wiki PowerPoint (2021-08-31 - Version 1.5.0.0) - Download - General Help & Support - Example Scripts - Wiki Task Scheduler (2022-07-28 - Version 1.6.0.1) - Download - General Help & Support - Wiki Standard UDFs: Excel - Example Scripts - Wiki Word - Wiki Tutorials: ADO - Wiki WebDriver - Wiki Link to comment Share on other sites More sharing options...
Moderators JLogan3o13 Posted July 24, 2019 Moderators Share Posted July 24, 2019 5 hours ago, Nine said: I do not know ahk and have no intent of learning it. Since this is an AutoIt forum, how about YOU learn AutoIt ! Post your code if you have trouble with it. We will then help you... I've noticed another rash of unhelpful opinionated comments from you lately. Look through the history of this forum and you will see many times where we've helped people transition from AHK to AutoIt, as there are many here who do know both languages. If you "have no intent of learning it" great, or have nothing to actually add to a post, keep moving and let someone who does want to help do so. FrancescoDiMuro and Werty 2 "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...
Moderators JLogan3o13 Posted July 24, 2019 Moderators Share Posted July 24, 2019 @nodelay GetKeyState just looks for the state of a keyboard key. Since you are using "physical" for the mode, look in the AutoIt help file for _IsPressed as an equivalent. "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...
nodelay Posted July 26, 2019 Author Share Posted July 26, 2019 On 7/24/2019 at 9:05 AM, JLogan3o13 said: @nodelay GetKeyState just looks for the state of a keyboard key. Since you are using "physical" for the mode, look in the AutoIt help file for _IsPressed as an equivalent. ok, i'll try. thx Link to comment Share on other sites More sharing options...
nodelay Posted July 26, 2019 Author Share Posted July 26, 2019 (edited) On 7/24/2019 at 3:03 AM, Nine said: I do not know ahk and have no intent of learning it. Since this is an AutoIt forum, how about YOU learn AutoIt ! Post your code if you have trouble with it. We will then help you... The objective of the script is a macro of "f1 + left click" by holding down f1, and pausing when released. sorry if the question is wrong, I'm trying to learn this Edited July 26, 2019 by nodelay Link to comment Share on other sites More sharing options...
FrancescoDiMuro Posted July 26, 2019 Share Posted July 26, 2019 @nodelay Don't worry. Many people comes from AHK and have the need to convert their scripts from AHK to AutoIt, but each of them at least did a try, and posted some AutoIt code, which makes whomever want to help, more induced in helping the user, so, make your tries, and when you need further help, post what you got, and someone will help you for sure Click here to see my signature: Spoiler ALWAYS GOOD TO READ: Forum Rules Forum Etiquette Link to comment Share on other sites More sharing options...
Seminko Posted July 26, 2019 Share Posted July 26, 2019 @nodelay not sure if this is what you're after, but here you go: #include <Misc.au3> While 1 Sleep(50) If _IsPressed(70) Then ; 'hex 70 is F1 (more here https://www.autoitscript.com/autoit3/docs/libfunctions/_IsPressed.htm)' Send("{F1}") MouseClick("left") EndIf WEnd Link to comment Share on other sites More sharing options...
nodelay Posted July 27, 2019 Author Share Posted July 27, 2019 22 hours ago, Seminko said: @nodelay not sure if this is what you're after, but here you go: #include <Misc.au3> While 1 Sleep(50) If _IsPressed(70) Then ; 'hex 70 is F1 (more here https://www.autoitscript.com/autoit3/docs/libfunctions/_IsPressed.htm)' Send("{F1}") MouseClick("left") EndIf WEnd oh thanks, this is really costing me, it's hard. Do not post anything I am doing because I am really somewhat lost. I'ts something new for me. The script does not work exactly as I am looking for it, but it is a great help to understand and be able to continue. Thank you <3 Link to comment Share on other sites More sharing options...
Seminko Posted July 27, 2019 Share Posted July 27, 2019 No worries, man. If you need further help on this, just let me know. 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