Microsoft KB Archive/25587

CTRL+PRINT SCREEN/CTRL+P Key Detection in MS-DOS PSS ID Number: Q25587 Article last modified on 08-27-1993 PSS database name: O_MSDOS

3.x 4.x 5.x 6.00

MS-DOS

= SUMMARY =

This article explains how the CTRL+PRINT SCREEN/CTRL+P are detected in MS-DOS.

= MORE INFORMATION =

You can read from the console using INT 21H, function 8H (character input without echo). To then read the console without MS-DOS processing a CTRL+C or CTRL+BREAK, you must use a lower-level read (Function 6H or 7H). However, MS-DOS then does not “see” the CTRL+PRINT SCREEN.

There is no way to toggle the CTRL+P key combination from software because there is no system call or flag. You could use one of the higher-level read functions and then set your own INT 23H handler that does nothing; this disables CTRL+C and CTRL+BREAK. INT 5H is the interrupt that is issued when you press the PRINT SCREEN key.

Additional reference words: 3.20 4.00 5.00 6.00

Copyright Microsoft Corporation 1993.