Which event occurs when user presses Ctrl+Alt+Del and then "Lock Computer"?
-
Hi I have a dialog based MFC application in which I want to handle an event which occurs when user presses Ctrl+Alt+Del and from Windows Security dialog it select "Lock Computer" button and it locks the computer. I want to know which event occurs and how to trap this event? Any help would be strongly appreciated. Mahesh
-
Hi I have a dialog based MFC application in which I want to handle an event which occurs when user presses Ctrl+Alt+Del and from Windows Security dialog it select "Lock Computer" button and it locks the computer. I want to know which event occurs and how to trap this event? Any help would be strongly appreciated. Mahesh
IIRC, you cannot "trap" the SAS (
CTRL-ALT-DEL
) due to security reasons. I am not sure if applications can register (or receive) notification that the system has been locked. You can also see an earlier post I made about Desktops in http://www.codeproject.com/script/comments/forums.asp?msg=1362087&forumid=1647#xx1362087xx[^]. Peace! -=- James
If you think it costs a lot to do it right, just wait until you find out how much it costs to do it wrong!
Tip for new SUV drivers: Professional Driver on Closed Course does not mean your Dumb Ass on a Public Road!
DeleteFXPFiles & CheckFavorites (Please rate this post!) -
Hi I have a dialog based MFC application in which I want to handle an event which occurs when user presses Ctrl+Alt+Del and from Windows Security dialog it select "Lock Computer" button and it locks the computer. I want to know which event occurs and how to trap this event? Any help would be strongly appreciated. Mahesh
Receiving notice when Ctrl+Alt+Del has been pressed will require your own GINA DLL. However, whenever the computer has been locked, see
ISensLogon::DisplayLock()
.
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
-
Receiving notice when Ctrl+Alt+Del has been pressed will require your own GINA DLL. However, whenever the computer has been locked, see
ISensLogon::DisplayLock()
.
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
-
Hi David... Thankx a lot for giving some time to my problem Isn't there any such message which we receive when it locks computer by pressing "Lock Computer" button. Like we receive "WM_QUERYENDSESSION" when it goes logoff event or shutdown event. Mahesh
Amarelia wrote:
Isn't there any such message which we receive when it locks computer by pressing "Lock Computer" button.
Perhaps, but I'm unaware of what it might be.
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
-
Hi I have a dialog based MFC application in which I want to handle an event which occurs when user presses Ctrl+Alt+Del and from Windows Security dialog it select "Lock Computer" button and it locks the computer. I want to know which event occurs and how to trap this event? Any help would be strongly appreciated. Mahesh
If you want to receive a notification about when the window station switches between locked states checkout the WTSRegisterSessionNotification[^] API, using it you can receive a
WM_WTSSESSION_CHANGE
message. Gavin Taylor w: http://www.gavspace.com -
Amarelia wrote:
Isn't there any such message which we receive when it locks computer by pressing "Lock Computer" button.
Perhaps, but I'm unaware of what it might be.
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
Checkout WTSRegisterSessionNotification[^] Gavin Taylor w: http://www.gavspace.com
-
Checkout WTSRegisterSessionNotification[^] Gavin Taylor w: http://www.gavspace.com
This seems like a Terminal Services solution, rather than a general-purpose one. Yes?
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
-
This seems like a Terminal Services solution, rather than a general-purpose one. Yes?
"The greatest good you can do for another is not just to share your riches but to reveal to him his own." - Benjamin Disraeli
Windows XP actually uses a dumbed down version of Terminal Services (for fast user switching / remote desktop, etc), I just tried it to double check myself and it does work. Gavin Taylor w: http://www.gavspace.com
-
If you want to receive a notification about when the window station switches between locked states checkout the WTSRegisterSessionNotification[^] API, using it you can receive a
WM_WTSSESSION_CHANGE
message. Gavin Taylor w: http://www.gavspace.com