FinalVersion Posted May 13, 2009 Share Posted May 13, 2009 My current code: While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit Case $Cmd ;Code Here EndSwitch WEnd Basically I want it to run the $cmd when enter is pushed. [center][+] Steam GUI [+][+] Clipboard Tool [+][+] System :: Uptime [+][+] StarCraft II Mouse Trap [+][/center] Link to comment Share on other sites More sharing options...
Zedna Posted May 13, 2009 Share Posted May 13, 2009 Look herehttp://www.autoitscript.com/forum/index.php?showtopic=66650 Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
nguyenbason Posted May 13, 2009 Share Posted May 13, 2009 SetHotkey({enter},$cmd) i hope it works for you. Forgive me if i show you wrong way UnderWorldVN- Just play the way you like it Link to comment Share on other sites More sharing options...
FinalVersion Posted May 13, 2009 Author Share Posted May 13, 2009 SetHotkey({enter},$cmd) i hope it works for you. Forgive me if i show you wrong way Already tried that rofl. [center][+] Steam GUI [+][+] Clipboard Tool [+][+] System :: Uptime [+][+] StarCraft II Mouse Trap [+][/center] Link to comment Share on other sites More sharing options...
Zedna Posted May 13, 2009 Share Posted May 13, 2009 Look at HotkeySet() in AutoIt's helpfile. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
FinalVersion Posted May 13, 2009 Author Share Posted May 13, 2009 Look at HotkeySet() in AutoIt's helpfile.I know he meant: HotKeySet("{ENTER}", $Cmd) It doesn't work. [center][+] Steam GUI [+][+] Clipboard Tool [+][+] System :: Uptime [+][+] StarCraft II Mouse Trap [+][/center] Link to comment Share on other sites More sharing options...
WideBoyDixon Posted May 13, 2009 Share Posted May 13, 2009 What is $cmd? Is it a button? If so, give it the $BS_DEFPUSHBUTTON style and it will be triggered when you press [Enter] anyway. WBD [center]Wide by name, Wide by nature and Wide by girth[u]Scripts[/u]{Hot Folders} {Screen Calipers} {Screen Crosshairs} {Cross-Process Subclassing} {GDI+ Clock} {ASCII Art Signatures}{Another GDI+ Clock} {Desktop Goldfish} {Game of Life} {3D Pie Chart} {Stock Tracker}[u]UDFs[/u]{_FileReplaceText} {_ArrayCompare} {_ToBase}~ My Scripts On Google Code ~[/center] Link to comment Share on other sites More sharing options...
Zedna Posted May 13, 2009 Share Posted May 13, 2009 I know he meant: HotKeySet("{ENTER}", $Cmd) It doesn't work. Look at HotkeySet() in AutoIt's helpfile. Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
CodyBarrett Posted May 13, 2009 Share Posted May 13, 2009 if _ispressed('0D') then _Function_ () [size="1"][font="Tahoma"][COMPLETED]-----[FAILED]-----[ONGOING]VolumeControl|Binary Converter|CPU Usage| Mouse Wrap |WinHide|Word Scrammbler|LOCKER|SCREEN FREEZE|Decisions Decisions|Version UDF|Recast Desktop Mask|TCP Multiclient EXAMPLE|BTCP|LANCR|UDP serverless|AIOCR|OECR|Recast Messenger|AU3C|Tik-Tak-Toe|Snakes & Ladders|BattleShips|TRON|SNAKE_____________________[u]I love the Helpfile it is my best friend.[/u][/font][/size] Link to comment Share on other sites More sharing options...
FinalVersion Posted May 14, 2009 Author Share Posted May 14, 2009 (edited) Look at HotkeySet() in AutoIt's helpfile.My Helpfile Doesn't Work. Don't suggest reinstalling Ai.And no it isn't a button. Edited May 14, 2009 by Godly [center][+] Steam GUI [+][+] Clipboard Tool [+][+] System :: Uptime [+][+] StarCraft II Mouse Trap [+][/center] Link to comment Share on other sites More sharing options...
Zedna Posted May 14, 2009 Share Posted May 14, 2009 (edited) My Helpfile Doesn't Work. Don't suggest reinstalling Ai.And no it isn't a button.Are you kidding!?!If you don't bother to look into helpfile then stop asking such simple/stupid questions here!I hope nobody will help you anymore. Edited May 14, 2009 by Zedna Resources UDF ResourcesEx UDF AutoIt Forum Search Link to comment Share on other sites More sharing options...
FinalVersion Posted May 14, 2009 Author Share Posted May 14, 2009 Are you kidding!?!If you don't bother to look into helpfile then stop asking such simple/stupid questions here!I hope nobody will help you anymore.Excuse me? I hope your banned / warned for that. [center][+] Steam GUI [+][+] Clipboard Tool [+][+] System :: Uptime [+][+] StarCraft II Mouse Trap [+][/center] Link to comment Share on other sites More sharing options...
FadetoGrey Posted May 14, 2009 Share Posted May 14, 2009 HEY HEY HEY!!! Calm down Zedna and Godly.. It's just a forum, no need to be hostile. Zedna, if he says the helpfile doesn't work then it probably doesn't work, and it doesn't actually show you how to hotkey a variable and that's why he has asked this in the forum. It's an interesting question and I myself would also like to know the answer for future reference. Thank you. Link to comment Share on other sites More sharing options...
BrettF Posted May 14, 2009 Share Posted May 14, 2009 Well how about using the online version of the help file?Well if he is to get some decent help, he should first check the helpfile, then he should search for his issue. After all of that, he should post here, including code that replicates the problem. At the moment no one knows the the hell $cmd is do we? We ain't no mind readers, and my crystal ball is cloudy, so I can't see what it is.And FadeToGrey, Zedna is correct. You haven't been here long, so you probably have no idea how annoying simple questions can be answered, just by doing what I outlined before. It's more annoying when the question was answered 10 seconds ago too...So how about you try that Cheers,Bret Vist my blog!UDFs: Opens The Default Mail Client | _LoginBox | Convert Reg to AU3 | BASS.au3 (BASS.dll) (Includes various BASS Libraries) | MultiLang.au3 (Multi-Language GUIs!)Example Scripts: Computer Info Telnet Server | "Secure" HTTP Server (Based on Manadar's Server)Software: AAMP- Advanced AutoIt Media Player | WorldCam | AYTU - Youtube Uploader Tutorials: Learning to Script with AutoIt V3Projects (Hardware + AutoIt): ArduinoUseful Links: AutoIt 1-2-3 | The AutoIt Downloads Section: | SciTE4AutoIt3 Full Version! Link to comment Share on other sites More sharing options...
program builder Posted May 24, 2009 Share Posted May 24, 2009 (edited) ;This should work. HotKeySet( "{enter}", "_enter") while 1 sleep(999999) wend Func _enter () send("{lwindown}{enter}{lwinup}") shellexecute("cmd") EndFunc;==>_Open ;if you dont want enter to work take out ;this line, send("{lwindown}{enter}{lwinup}") Edited May 24, 2009 by program builder 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