buzz44 Posted December 28, 2004 Share Posted December 28, 2004 hello everyone, im new and have only started using autoit about a week ago , i have a problem i need to change the "-" key, so instead of displaying a "-" when u press it , it displays "ÿ". i know the"ÿ" is Send("{ALT 0255}") and "-" is Send("{-}") but i dont know the command to swap these keys, if possible at all, i have tried the ControlSetKey command and have has no luck if that is the command to use any way. can someone plz aid me in this. Thankyou for your help qq Link to comment Share on other sites More sharing options...
JSThePatriot Posted December 28, 2004 Share Posted December 28, 2004 What you are wanting to do is similar to a HotKeySet() have you checked that function yet? JS AutoIt Links File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out. ComputerGetInfo UDF's Updated! 11-23-2006 External Links Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more) Link to comment Share on other sites More sharing options...
buzz44 Posted December 28, 2004 Author Share Posted December 28, 2004 What you are wanting to do is similar to a HotKeySet() have you checked that function yet?JS<{POST_SNAPBACK}>dear js,yes i have checked that function but i couldnt get it to work, probibly because i didnt understand the inputs, ie, from help fileSets a hotkey that calls a user function.HotKeySet ( "key" [, "function"] ) i am not familiar, with the function inputi did try something likeHotKeySet ( "{-}", "hello") Func helloSend("{ALT 0255}")EndFuncBut had no such luck JS qq Link to comment Share on other sites More sharing options...
layer Posted December 28, 2004 Share Posted December 28, 2004 or trying searhing for these functions... StringReplace and StringSplit FootbaG Link to comment Share on other sites More sharing options...
SlimShady Posted December 28, 2004 Share Posted December 28, 2004 (edited) I just tested this and it works. With both dash keys. HotKeySet("-", "Y_Umlaut") HotKeySet("{NUMPADSUB}", "Y_Umlaut") While 1 Sleep(100) WEnd Func Y_Umlaut() Send(Chr(255)) EndFunc Edited December 28, 2004 by SlimShady Link to comment Share on other sites More sharing options...
this-is-me Posted December 28, 2004 Share Posted December 28, 2004 (edited) <- ME Edited December 28, 2004 by this-is-me Who else would I be? Link to comment Share on other sites More sharing options...
JSThePatriot Posted December 28, 2004 Share Posted December 28, 2004 (edited) dear js,yes i have checked that function but i couldnt get it to work, probibly because i didnt understand the inputs, ie, from help fileSets a hotkey that calls a user function.HotKeySet ( "key" [, "function"] ) i am not familiar, with the function inputi did try something likeHotKeySet ( "{-}", "hello") Func helloSend("{ALT 0255}")EndFuncBut had no such luck JS<{POST_SNAPBACK}>Your syntax was a bit off. The only time you use the {} (curly brackets) is when you are sending keys. (Just a note )HotKeySet("-", "Hello") Func Hello Send("{ALT 0255}") EndFuncEdit: See Slim's code he gave you the full complete script. Enjoy.I hope that helps some,JS Edited December 28, 2004 by JSThePatriot AutoIt Links File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out. ComputerGetInfo UDF's Updated! 11-23-2006 External Links Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more) Link to comment Share on other sites More sharing options...
this-is-me Posted December 28, 2004 Share Posted December 28, 2004 (edited) <- ME Edited December 28, 2004 by this-is-me Who else would I be? Link to comment Share on other sites More sharing options...
buzz44 Posted December 28, 2004 Author Share Posted December 28, 2004 Thankyou very much, i just tried your code slimshady and it works fine thankyou, i was wondering if u could also help me make coding so that, if u hit INSERT it will run the script and if u hit DELETE it will return the keys to there original value and quit, your inout would be much appreciated, and thankyou every1 else for your input qq Link to comment Share on other sites More sharing options...
SlimShady Posted December 28, 2004 Share Posted December 28, 2004 (edited) You can't run a file automatically. To quit the following script, press DELETE. As you wanted. Check and learn. HotKeySet("-", "Y_Umlaut") HotKeySet("{DELETE}", "Quit") HotKeySet("{NUMPADSUB}", "Y_Umlaut") While 1 Sleep(100) WEnd Func Y_Umlaut() Send(Chr(255)) EndFunc Func Quit() HotKeySet("-") HotKeySet("{DELETE}") HotKeySet("{NUMPADSUB}") EXIT EndFunc For future reference. See if you can use the help file. If you have problems with it or if you don't understand something, post here. Edited December 28, 2004 by SlimShady 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