How to restrict user from closing an application
-
Hi Can anybody tell me how to restrict user from closing an application. The scenario is, I have developed a time controller/recorder for users. Input form displays in the startup. User sets time on it and then it goes to systray and after the set time has passed, it shutsdown the system after givia warning or, if user wishes to do so, allows him to start another session. I have removed the control box but the problem is that the user can still close it with Alt + F4 Command. Thanks How this can be handled?
reman
-
Hi Can anybody tell me how to restrict user from closing an application. The scenario is, I have developed a time controller/recorder for users. Input form displays in the startup. User sets time on it and then it goes to systray and after the set time has passed, it shutsdown the system after givia warning or, if user wishes to do so, allows him to start another session. I have removed the control box but the problem is that the user can still close it with Alt + F4 Command. Thanks How this can be handled?
reman
I don't think you'll ever be able to compleatly stop the user from shutting down the application if they want to without resorting to use a Group Policy to lock down the machine. Even if you stop alt-f4 they can still use the taskamanager to kill the process.
-
I don't think you'll ever be able to compleatly stop the user from shutting down the application if they want to without resorting to use a Group Policy to lock down the machine. Even if you stop alt-f4 they can still use the taskamanager to kill the process.
originSH wrote:
taskamanager to kill the process
Process permissions? Normally users can kill processes running as Windows services right?
Vasudevan Deepak Kumar Personal Homepage Tech Gossips
-
originSH wrote:
taskamanager to kill the process
Process permissions? Normally users can kill processes running as Windows services right?
Vasudevan Deepak Kumar Personal Homepage Tech Gossips
-
Windows services can be killed unless they are running as a system account. But you shouldn't have an app that can interact with the desktop running as the system account ;) It then also creates more problems when you want to use the users credentials.
IIRC the way to do it is to have a service running as system with all the logic, and a UI only app running in userland and use IPC to have the service feed data into the apps UI and restart it if closed.
-- You have to explain to them [VB coders] what you mean by "typed". their first response is likely to be something like, "Of course my code is typed. Do you think i magically project it onto the screen with the power of my mind?" --- John Simmons / outlaw programmer
-
IIRC the way to do it is to have a service running as system with all the logic, and a UI only app running in userland and use IPC to have the service feed data into the apps UI and restart it if closed.
-- You have to explain to them [VB coders] what you mean by "typed". their first response is likely to be something like, "Of course my code is typed. Do you think i magically project it onto the screen with the power of my mind?" --- John Simmons / outlaw programmer
Hmmmm thats a nice solution :) I'm currently working on Web Service using IPC remoting for talking with its front end. It would'nt take much more for it to monitor and restart the front end. It's also nice how in the future it should be relativly easy to switch over to tcp remoting and have a central management app :D