31290

Hotkey to release a blockinput

9 posts in this topic

Hi Everyone, 

I'm trying to find a way to assign a hotkey to stop a blockinput function, just in case anything goes wrong in my script.

I took a look here :

'?do=embed' frameborder='0' data-embedContent>>

I also did some tests but this UDF "only" allows me to exclude some keys whereas I need a simple hotkey, F1 for example, that will release the blockinput.

Maybe someone can give me a hand over here :)

Thanks in advance,

31290.


~~~ Doom Shall Never Die, Only The Players ~~~

Share this post


Link to post
Share on other sites



You do realize why it is a bad idea to want user input to to stop a function that blocks user input right?

If you are using BlockInput for any length of time where something might go wrong, you are probably using it foolishly to begin with too.


AutoIt Absolute Beginners    Require a serial    Pause Script    Video Tutorials by Morthawt   ipify 

Monkey's are, like, natures humans.

Share this post


Link to post
Share on other sites

You do realize why it is a bad idea to want user input to to stop a function that blocks user input right?

If you are using BlockInput for any length of time where something might go wrong, you are probably using it foolishly to begin with too.

 

Yes I realized that but this is a requirement from my bosses.

If anything goes wrong during the script execution, there's no way the users will have to reboot the computer to unlock mouse & keyboard.

That's why I have to find a way to create a rescue key.


~~~ Doom Shall Never Die, Only The Players ~~~

Share this post


Link to post
Share on other sites

well Ctrl-alt-del override blockinput in autoit anyway, or m'i wrong?

Share this post


Link to post
Share on other sites

Two way :

Hotckeyset ("{F10}","BlockinputOff")  

Func BlockinputOff ()

        BlockInput = 0

EndFunc

Or CTRL + ALT + SUPR

If you need a manual blockinput emergency shutoff both way are OK

Share this post


Link to post
Share on other sites

well Ctrl-alt-del override blockinput in autoit anyway, or m'i wrong?

 

CTRL-ALT-DEL override blockinput as you said but as soon as I return to Windows or open Task Manager, the blockinput is back and you can't do anything.

 

Two way :

Hotckeyset ("{F10}","BlockinputOff")  

Func BlockinputOff ()

        BlockInput = 0

EndFunc

Or CTRL + ALT + SUPR

If you need a manual blockinput emergency shutoff both way are OK

 

Thanks, I'm gonna try and let you know :)


~~~ Doom Shall Never Die, Only The Players ~~~

Share this post


Link to post
Share on other sites

Sorry for the late response but thanks JohnOne, that helped a lot :)


~~~ Doom Shall Never Die, Only The Players ~~~

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