zvd Posted January 19, 2007 Share Posted January 19, 2007 Hello, I would like to make a compiled .au3 executable (program.exe) that runs a gui/program on double-click, but also, when you type the path of the program.exe in the Start -> Run -> Open box and add flags such as /x or /? it calls other functions or help messages (without running program.exe). Any ideas on how to do this? Thanks! Link to comment Share on other sites More sharing options...
Paulie Posted January 19, 2007 Share Posted January 19, 2007 (edited) ... also, when you type the path of the program.exe in the Start -> Run -> Open box and add flags such as /x or /? it calls other functions or help messages (without running program.exe). Any ideas on how to do this? Thanks!Check out Command Line Parameters in the helpfile they will do just this As for doubleClick detection, the only way i can think of is this: #include <Misc.au3> While 1 If _IsPressed(01) Then While _IsPressed(01) Sleep(2) WEnd Sleep(100);You may have to adjust if you have a really fast/slow click If _IsPressed(01) Then MsgBox(0,"Double Click", "You Double Clicked!") EndIf EndIf WEnd Its kind of a workaround, I'm sure there is a better way, but that catches most of my double Clicks Edited January 19, 2007 by Paulie Link to comment Share on other sites More sharing options...
zvd Posted January 20, 2007 Author Share Posted January 20, 2007 Not really what I had in mind. Making the program.exe open on double-click is just the regular behavior of a compiled .au3 script. I want to add the additional "feature" of a /? switch/flag that pops up a message box or something. Link to comment Share on other sites More sharing options...
MHz Posted January 20, 2007 Share Posted January 20, 2007 As mentioned by Paulie.http://www.autoitscript.com/autoit3/docs/i...htm#CommandLineSee if that helpsTo check for incoming script parametersIf $CMDLINE[0] Then MsgBox(0, 'first switch is', $CMDLINE[1]) EndIf Link to comment Share on other sites More sharing options...
zvd Posted January 20, 2007 Author Share Posted January 20, 2007 Great. Thanks alot. That got me started... 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