5

I am creating a desktop application using the JDesktopPane. I'm almost complete, but when I press ctrl + alt + del, it leaves my application. How can I prevent that action?

ljs.dev
  • 4,449
  • 3
  • 47
  • 80
Arivu2020
  • 2,485
  • 7
  • 25
  • 24
  • 6
    As I'm not certain, I won't offer an official answer, but I don't believe it is possible. On Windows, ctrl-alt-del is a reserved key combination. It would be a security flaw to allow applications the ability to override it. – D.C. Apr 11 '10 at 07:47

4 Answers4

11

Fact is Alt+Ctrl+Del never actually entering your application. Os traps Alt+Ctrl+Del before it is send to your application. So you can't trap it.

Thomas Abraham
  • 356
  • 2
  • 9
8

Alt+Ctrl+Del cannot be overridden. It is a security feature.

Thomas Abraham
  • 356
  • 2
  • 9
sabbour
  • 4,969
  • 6
  • 34
  • 33
7

You cannot do that. The behavior of Alt+Ctrl+Del is enforced by the operating system, for good reasons: it makes sure that you can always bail-out of a faulty application.

Thomas Abraham
  • 356
  • 2
  • 9
Itay Maman
  • 30,277
  • 10
  • 88
  • 118
5

http://www.codeproject.com/KB/winsdk/AntonioWinLock.aspx

lists several possibilities, from disabling the taskmanager to injecting keyboard hooks. But I doubt there's some built-in java functionality for that.

Wikser
  • 810
  • 7
  • 11