FRIHOST FORUMS SEARCH FAQ TOS BLOGS COMPETITIONS
You are invited to Log in or Register a free Frihost Account!


disabling keys in VB6





kawkazEE
im tryin to make a cafe management for my friends business. in the client side i want to disable keys (start button, alt+f4, alt+tab, ctrl+alt+delete). anybody knows how to do this... please help!
CWSwim
you'll need to use the API Application program interface. check out URL: http://www.allapi.net/
great resource for api's.
deepak
I dont know why you'r not using Javascript if you've web based interface. But if you've some win32 application then use

To disable CTRL+ALT+DEL and CTRL+ESC, use the following code :
________________________________________________________________

DECLARATION / FUNCTION (place in module):

Public Declare Function SystemParametersInfo Lib "user32" Alias "SystemParametersInfoA" (ByVal uAction As Long, ByVal uParam As Long, ByVal lpvParam As Any, ByVal fuWinIni As Long) As Long

Public Sub DisableCtrlAltDelete(bDisabled As Boolean)
Dim X As Long
X = SystemParametersInfo(97, bDisabled, CStr(1), 0)
End Sub


USE (place in your code where you want to use it):

'To disable Ctrl-Alt-Delete:
Call DisableCtrlAltDelete(True)

'To enable Ctrl-Alt-Delete:
Call DisableCtrlAltDelete(False)
________________________________________________________________

To disable ALT+F4, on the form that you think they will do an ALT+F4, put a private Boolean variable in the General/Declarations section, then test that Boolean variable in the Form_Unload event. If your program hasn't set it to TRUE, then set "Cancel = True". This will stop the unloading of your form/program. If you want to close your program, set that Boolean variable to TRUE, then unload all forms, and/or use the End statement
Related topics
Keys to one Success
Windows Vista Official Thread
[RESOLVED] Does anyone know what OpenPGP Keys are used for?
HELP in VB6 and MySQL
Windows XP Tricks & Tips!!!!
Acer Notebook multimedia keys
VB6 Login
Wireles connection & mac keys - help! :)
VB6 and data reports
[VB6]Making a Scriptable Macro/Engine
The Black Keys
Arrow keys for ksh
"Sticky Keys"/Language changing
Debian/Ubuntu Users - garbage ssh keys
Reply to topic    Frihost Forum Index -> Scripting -> Others

FRIHOST HOME | FAQ | TOS | ABOUT US | CONTACT US | SITE MAP
© 2005-2011 Frihost, forums powered by phpBB.