Sign in to follow this  
Followers 0
Program

How to exit script, keys and mouse disabled

8 posts in this topic

Hi,

I was thinking of implenting my script so that a user cannot interfere by using the mouse or keyboard until it finishes.

However i am hesitant to use this as i have found that my script doesnt work sometimes and i need to right click the icon and exit it manually.

If i disable keyboard and mouse functionality, is there a way to manually exit the script? Or would the only way to exit be to reset the machine?

Thanks in advance

Share this post


Link to post
Share on other sites



If i disable functionality can i send say ALT+S within the script? or would that be blocked too? Im talkin about WINXP.....

Is any script "Send" functionality blocked?

Share this post


Link to post
Share on other sites

Is any script "Send" functionality blocked?

Not unless you are using Windows 98, ME, but the rest should be fine. See also: BlockInput in the helpfile for more information regarding the effect BlockInput(1) has on systems.

[font="Optima"]"Standing in the rain, twisted and insane, we are holding onto nothing.Feeling every breath, holding no regrets, we're still looking out for something."[/font]Note: my projects are off-line until I can spend more time to make them compatable with syntax changes.

Share this post


Link to post
Share on other sites

When i use the command

BlockInput(1)

at the beginning of a script, i expect that when the script is run, a user cannot actively click on the desktop with the mouse or the keyboard doesnt work until the script exits.

However when i run the script i can click the mouse on the desktop just as though the script wasnt running...!

Is there anything else that must be added to the script apart from the above?

:D

Share this post


Link to post
Share on other sites

Is there anything else that must be added to the script apart from the above?

No, that is the command to use. Please note the following table (coppied from the helpfile.) If your system matches "no effect" then the BlockInput call will do no good until you change your OS.

Windows 95 - No effect.

Windows 98/Me - User input is blocked but AutoIt is also unable to simulate input.

Windows NT 4 (Without ServicePack 6) - No effect.

Windows NT 4 (With ServicePack 6) - User input is blocked and AutoIt can simulate most input.

Windows 2000/XP - User input is blocked and AutoIt can simulate most input.


[font="Optima"]"Standing in the rain, twisted and insane, we are holding onto nothing.Feeling every breath, holding no regrets, we're still looking out for something."[/font]Note: my projects are off-line until I can spend more time to make them compatable with syntax changes.

Share this post


Link to post
Share on other sites

Yeah sorry,

that was my stupid fault, i was testing my script on a remote machine where i was using a remote desktop utility (winvnc) that allowed me to utilize the remote mouse. However when i physically went to the machine all functionality was disabled!

Ta :D

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