bobheart 0 Posted August 19, 2004 How would you do this in autoit :SetKeyDelay 90 InputBox, OutputVar, Enter your e-mail address.MsgBox You entered %OutputVar%. !z::Send,{AltUp}{Alt}%OutputVar%This was done in autohotkey .Or is it the same ? Share this post Link to post Share on other sites
this-is-me 6 Posted August 19, 2004 SendKeyDelay(90) $OutputVar = InputBox("", "Enter your e-mail address.") MsgBox(0,"","You entered " & $OutputVar & ".") I am not sure about that last line. Look at the autoit help file for more info. Nearly every question you want answered is there. Who else would I be? Share this post Link to post Share on other sites
bobheart 0 Posted August 19, 2004 first line error --------------------------- AutoIt Error --------------------------- Line 1 (File "C:\Documents and Settings\bob\My Documents\email_key.au3"): SendKeyDelay(90) ^ ERROR Error: Unknown function name. Share this post Link to post Share on other sites
Josbe 1 Posted August 19, 2004 first line error --------------------------- AutoIt Error --------------------------- Line 1 (File "C:\Documents and Settings\bob\My Documents\email_key.au3"): SendKeyDelay(90) ^ ERROR Error: Unknown function name. <{POST_SNAPBACK}>Opt("SendKeyDelay", 90) AUTOIT > AutoIt docs / Beta folder - AutoIt latest beta Share this post Link to post Share on other sites
bobheart 0 Posted August 19, 2004 (edited) I guess this-is-me should look in that help file . lol And it is still not sending the email address to the window . This suppost to send the email address to a window so you don't have to copy and paste it over and over again so it needs to seit in the system tray and work and it does not . Edited August 19, 2004 by bobheart Share this post Link to post Share on other sites
this-is-me 6 Posted August 19, 2004 (edited) sry. I threw it together at the last minute. Edited August 19, 2004 by this-is-me Who else would I be? Share this post Link to post Share on other sites
bobheart 0 Posted August 20, 2004 Hey n/p ") I can still do it with the autohotkey . Share this post Link to post Share on other sites
Jon 1,009 Posted August 20, 2004 (edited) Well the code equivalent is this: Opt("SendKeyDelay", 90) $OutputVar = InputBox("", "Enter your e-mail address.") MsgBox(0,"","You entered " & $OutputVar & ".") ; Set the hotkey HotKeySet("!z", "SendEmail") ; Just wait around for the user to press a key While 1 Sleep(1000) WEnd ; The function that performs the Send Func SendEmail() Send($OutputVar) EndFunc But it doesn't quite work correctly as the send function gets confused that the alt key is already held down (from the hotkey). I'll see if there is any easy fix. Edited August 20, 2004 by Jon Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Share this post Link to post Share on other sites
Jon 1,009 Posted August 20, 2004 If you add the SendAttachMode option the script works: Opt("SendKeyDelay", 90) Opt("SendAttachMode", 1) $OutputVar = InputBox("", "Enter your e-mail address.") MsgBox(0,"","You entered " & $OutputVar & ".") ; Set the hotkey HotKeySet("!z", "SendEmail") ; Just wait around for the user to press a key While 1 Sleep(1000) WEnd ; The function that performs the Send Func SendEmail() Send($OutputVar) EndFunc For those that don't know, the SendAttachMode option causes AutoIt to "attach" to the window it is sending too which allows much better detection of if the user is already holding keys down (like in this case the user will be holding down Alt+Z when the send begins). This mode used to be the default but there are a couple of drawbacks when using the {... down} and {... up} send modes. I actually thought I'd left it as the default and might change it back as the up/down modes are only useful to gamer types anyway Deployment Blog: https://www.autoitconsulting.com/site/blog/ SCCM SDK Programming: https://www.autoitconsulting.com/site/sccm-sdk/ Share this post Link to post Share on other sites