Sign in to follow this  
Followers 0
tzerber

Send problems

5 posts in this topic

#1 ·  Posted (edited)

Hello to all :mellow:

i have problem with the Send command (i found this script somewhere here but can`t rly remember from where.)

using this script cause of stuck ctrl key when i use hotkey combination

#include <Misc.au3>
;Send the string $ss after the Shift Alt and Ctrl keys are released.
;Optionally give a warning after 1 sec if any of those keys still down.
;Requires misc.au3 to be included in the script for the _IsPressed function.

Func _SendEx($ss, $warn = "")
    Local $iT = TimerInit()

    While _IsPressed("10") Or _IsPressed("11") Or _IsPressed("12")
        If $warn <> "" And TimerDiff($iT) > 1000 Then
            MsgBox(262144, "Warning", $warn)
        EndIf
        Sleep(50)
    WEnd
    $ss = Asc($ss)
    Send("{" & $ss & "}")

    Send($ss)
EndFunc;

My question is : can i use other command to "Send" a key to window? (seems the window is protected and send don`t work, spent some time to test it and the window just don`t accept the commands, that the program is sending)

also i have similar problem with mouse but i`ll leave this for later

Edited by tzerber

Share this post


Link to post
Share on other sites



just bumping this thread :mellow:

still need help with this

Share this post


Link to post
Share on other sites

Hi,

yes there is another way to send info to a window and it's called Control Send. Use the Window info tool to get some information about your window and where you want to send the information to and read up on control send.

I would suggest ditching your above code until you get the basics working.

good luck

Share this post


Link to post
Share on other sites

ok that seems working but i have problems with some keys.

before i was using this :

AutoItSetOption ( "SendKeyDelay", 200 )
AutoItsetoption ( "SendKeyDownDelay", 200)
_sendEX($tempData)
AutoItSetOption ( "SendKeyDelay", 0 )
AutoItsetoption ( "SendKeyDownDelay", 50)

but if i use ControlSend delays seems not working. any ideas how to fix this ?

Share this post


Link to post
Share on other sites

bump bump :blink:

Share this post


Link to post
Share on other sites

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 account

Sign in

Already have an account? Sign in here.


Sign In Now
Sign in to follow this  
Followers 0