Jump to content

Blocking the mouse


Nova
 Share

Recommended Posts

Guest Py7|-|[]/\/

You can force the mouse in the beginning of the script to stay in one place...

While 1

MouseClick("left", x, y, 1, 0)

WEnd

Link to comment
Share on other sites

that wouldn't work while a script is running because you would be stuck in the while statement. However, you could make a file with the name of your script. (myscript.exe):

Run("myrealscript.exe")
While 1
MouseMove(1, 1, 1)
Wend

And make myrealscript.exe your real script. Then when you want to run it open myscript.exe.

My site for HTML Help :)[quote name='Valik' date='Oct 15 2004, 12:29 PM']Maybe nobody is an "elite uber-coder" like me because thinking is a capital offense in today's online-world?[right][snapback]36427[/snapback][/right][/quote]
Link to comment
Share on other sites

Na that no use really,it looks really cheep u cna still drag the mouse on screen for a few seconds with a quick slide of the mouse !

I need the mouse to be disabled not partially hidden off screen with a flickering madness :idiot:

Link to comment
Share on other sites

Does not MouseTrap need a struct as parameter? Do AutoIt (as is) manage it?

Its in here somewhere, 8th post down I think !

http://www.autoitscript.com/forum/index.ph...lite=mouse+trap

Im a bit confussed doI have to specify the location of the dllwhen running ti or put it in the same folder as teh script calling it ?

Edited by nova
Link to comment
Share on other sites

DLLCall("AU3Xtra.dll", "int", "MouseTrap", "int", 0, "int", 0, "int", 0, "int", 0 )
Sleep(5000)
DLLCall( "AU3Xtra.dll", "int", "MouseTrap", "int", -1, "int", -1, "int", -1, "int", -1 )

The above code traps the mouse in the topleft corner of my screen

I cant seem to force the mouse off screen with minus cordinates or off screen with huge plus coridinates.

My screen res is 800x600

ive tryed

DLLCall("AU3Xtra.dll", "int", "MouseTrap", "int", -100, "int", 0, "int", 0, "int", 0 )
Sleep(5000)
DLLCall( "AU3Xtra.dll", "int", "MouseTrap", "int", -1, "int", -1, "int", -1, "int", -1 )

and

DLLCall("AU3Xtra.dll", "int", "MouseTrap", "int", 900, "int", 0, "int", 0, "int", 0 )
Sleep(5000)
DLLCall( "AU3Xtra.dll", "int", "MouseTrap", "int", -1, "int", -1, "int", -1, "int", -1 )

I know ur function is called mouse trap but can I use it to trap the mouse off screen <hidden> ?

Link to comment
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
 Share

  • Recently Browsing   0 members

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