HOWTO: Block CTRL+ALT+DEL and ALT+TAB in Windows 95 in VBLast reviewed: October 16, 1997Article ID: Q154868 |
The information in this article applies to:
SUMMARY It is possible to prevent the CTRL+ALT+DEL and ALT+TAB key combinations from bringing up the task list in Windows 95 by calling a function in the Win32 API. This article demonstrates this procedure. NOTE: This is possible only in Windows 95.
MORE INFORMATIONIt may be necessary for a program to prevent users from pressing the CTRL+ALT+DEL key combination to bring up the Close Program task list in Windows 95 from where they can end a task or shut down the system. This can be done using the SystemParametersInfo API. A sample program demonstrating this is given below. Note that disabling CTRL+ALT+DEL is not recommended because the Close Program dialog was created to allow misbehaving applications to be terminated. If a program "hangs" while CTRL+ALT+DEL is disabled, it may not be possible to terminate it by any method other than a hardware reboot of the machine, possibly resulting in loss of data. Also, this technique may not work in future versions of Windows. The technique involves tricking Windows 95 into thinking that a screen saver is running. A side effect of this is that CTRL+ALT+DEL no longer has any affect. The Win32 SDK states:
"SPI_SCREENSAVERRUNNING Windows 95: Used internally; applications should not use this flag. Windows NT: Not supported." Step-by-Step Example
REFERENCESSystemParametersInfo is documented in the Win32 SDK available in the MSDN/Visual Basic Starter Kit that can be installed from the CD-ROM version of Visual Basic 4.0, Professional and Enterprise Editions. Install by running SETUP.EXE in the MSDN directory on the CD-ROM. It is also available in the MSDN Development Library that is available under subscription from Microsoft.
|
Additional query words: reboot
© 1998 Microsoft Corporation. All rights reserved. Terms of Use. |