Jump to content

Windows 7 Send / MouseClick not working


 Share

Recommended Posts

Hi everyone,

I seem to have problems with AutoIt's Send and MouseClick function not working. Literally nothing happens when I call these functions. I tried to start notepad, waited for the window to appear and then used Send() to type some text. This does not work. When I use ControlSend it does work. Only in the program I'm trying to automate I cannot use ControlSend because it's not build using Windows Controls.

Strange thing is that it used to work perfectly well, even with Windows 7, maybe Service Pack 1 broke it. I am currently using the latest version of AutoIt. I've tried to run the program as admin an added #RequireAdmin to the script but this does not seem to affect anything.

Hope someone can help me out, thanks!

p.s.: These are the code samples I used to test.

Not working:

Run("notepad.exe")
Sleep(1000)
Send("This is a line of text in the notepad window")
debug("DONE")
exit

Working code:

Run("notepad.exe")
Sleep(1000)
ControlSend("[CLASS:Notepad]", "", "Edit1", "This is a line of text in the notepad window")
debug("DONE")
exit
Link to comment
Share on other sites

Just verified and it does not seem to be Windows 7 SP1 either. It still works on that PC and still does not work on another. On the computer where it does not work I have disabled and closed all background programs as well as other programs. Also UAC is off and AVG Antivirus disabled but still no luck. I do not know what else to try.

Link to comment
Share on other sites

strange... you say that UAC is disabled, but try this anyway... add #requireadmin at the top... i have win7 too but i never have that issue

Thanks for the tip but I all ready did that and it doesn't seem to help :mellow: .
Link to comment
Share on other sites

Hi!

Debug was a function of mine that shows a MsgBox :mellow: . I have found the problem, it was caused because of the fact that I run Synergy ( http://synergy-foss.org/ ) a while a go and I totally forgot about it but it was still in the background! It seems to capture the input of the mouse and keyboard and that causes the problem.

Thanks for the help!

Link to comment
Share on other sites

  • 10 months later...

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
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...