Jump to content

disable keys with auutoit?


cr0x
 Share

Recommended Posts

  • Moderators

I would recommend getting a keyboard with a Fn key. Usually Fn+F11 disables the keyboard. That or unplug the keyboard when you leave. Also HotkeySet() dosn't work for the mouse.

That's when you used _IsPressed() :o

Common sense plays a role in the basics of understanding AutoIt... If you're lacking in that, do us all a favor, and step away from the computer.

Link to comment
Share on other sites

hm but HotKeySet("{ESC}", "a") does not work.

if i try 2 start the script " Unknown function name.: HotKeySet("{ESC}", "a") " appears

HI,

you want something strange like

HotKeySet("{ESC}", "a")

while 1
    sleep(100000000)
WEnd

Func a()
;MsgBox(0,"","jo")
EndFunc

????

So long,

Mega

Edited by th.meger

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

Has everyone forgotten or just dont know about BlockInput()?

HotKeySet("^!s", "_Start");CTRL+ALT+s starts the block
HotKeySet("^!x", "_End");CTRL+ALT+x ends the block
HotKeySet("{ESC}", "_Exit");ESC exits the program

While 1
    Sleep(10)
WEnd

Func _Start()
    BlockInput(1)
EndFunc

Func _End()
    BlockInput(0)
EndFunc

Func _Exit()
    Exit
EndFunc

@Valuater

If your code uses BlockInput ignore this post hehe.

I hope the above helps with the situation,

JS

AutoIt Links

File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out.

ComputerGetInfo UDF's Updated! 11-23-2006

External Links

Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more)

Link to comment
Share on other sites

HotKeySet("^!s", "_Start");CTRL+ALT+s starts the block

HotKeySet("^!x", "_End");CTRL+ALT+x ends the block

HotKeySet("{ESC}", "_Exit");ESC exits the program

While 1

Sleep(10)

WEnd

Func _Start()

BlockInput(1)

EndFunc

Func _End()

BlockInput(0)

EndFunc

Func _Exit()

Exit

EndFunc

How should that (HotKeySet("^!x", "_End");CTRL+ALT+x ends the block) work if keybord is already blocked???? :o

So long,

Mega

Edited by th.meger

Scripts & functions Organize Includes Let Scite organize the include files

Yahtzee The game "Yahtzee" (Kniffel, DiceLion)

LoginWrapper Secure scripts by adding a query (authentication)

_RunOnlyOnThis UDF Make sure that a script can only be executed on ... (Windows / HD / ...)

Internet-Café Server/Client Application Open CD, Start Browser, Lock remote client, etc.

MultipleFuncsWithOneHotkey Start different funcs by hitting one hotkey different times

Link to comment
Share on other sites

CTRL+ALT+x does not unblock input as you cant input it. The only way to unblock input is to use CTRL+ALT+DEL as it says in the help file.

EDIT - Too slow again.

Edited by BigDod


Time you enjoyed wasting is not wasted time ......T.S. Elliot
Suspense is worse than disappointment................Robert Burns
God help the man who won't help himself, because no-one else will...........My Grandmother

Link to comment
Share on other sites

How should that (HotKeySet("^!x", "_End");CTRL+ALT+x ends the block) work if keybord is already blocked???? :o

So long,

Mega

CTRL+ALT+x does not unblock input as you cant input it. The only way to unblock input is to use CTRL+ALT+DEL as it says in the help file.

EDIT - Too slow again.

You both caught me!! lol :geek:

I cant believe I did that. haha

@=sinister=

I thought he wanted the mouse blocked as well.

Anyways... use the CTRL+ALT+DEL to end the BlockInput ;)

JS

AutoIt Links

File-String Hash Plugin Updated! 04-02-2008 Plugins have been discontinued. I just found out.

ComputerGetInfo UDF's Updated! 11-23-2006

External Links

Vortex Revolutions Engineer / Inventor (Web, Desktop, and Mobile Applications, Hardware Gizmos, Consulting, and more)

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...