Should not end my Application processes via Task Manager
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
You can't. Many others have asked that over the years. You probably won't be the last either. :sigh:
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
I don't know of a way to do this, and I'd strongly consider beating you severely if you did this to me. I stopped using Internet Explorer because I got tired of it launching multiple instances of itself that consume 100% of resources over time. Acrobat Reader does the same thing. Without the ability to kill a process in Task Manager, your application is no better than a virus. That being said, certain users in a business environment should be restricted from accessing Task Manager at all. That's simply good security practice, and can be accomplished by an Administrator using Group Policies. Look into Group Policy management if you want to do this for a legitimate reason.
"A Journey of a Thousand Rest Stops Begins with a Single Movement"
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
You can't. Since your app is launched by the user, it runs AS the user. The user can kill any process they launch and there's nothing you can do about it.
A guide to posting questions on CodeProject[^]
Dave Kreskowiak -
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
You can, actually.. at least under XP. But that would make your program malware, so I'm not going to help with that. On a related note, you can easily (without hacks) make it so that your program will not close when "killed" from the Applications list. It can still be closed from the Processes list, so that wouldn't make it malware. If you have a Form, subscribe to the
FormClosing
event and sete.Cancel
totrue
. -
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
You can have your processes save their state at regular intervals, and run a second "shadow" process that monitors the primary processes. When the shadow process detects that one of the primary processes was stopped (e.g. with Task Manager), it restarts that process, using that process' saved state to pick up where it left off.
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
krishnavaradharajan wrote:
no one should kill my processes through Task Manager.
And what are you going to do, if the user tripped the power cable? Why do you want to prevent the user from killing your buggy application.
Yusuf May I help you?
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
Remember that it is your software, but it is not your computer! All the tricks you can apply to prevent the owner of the computer from closing an application running on it could be considered as not politically correct!
-
Hi, When i am running a browser ( which i was created in windows application ), no one should kill my processes through Task Manager. How can i do this. Thanks.
krishna
Can you tell us why you'd like to implement this behavior? There may be a more acceptable means of meeting your requirements (which may be perfectly valid), but it's hard to guess without a use case. If you stated the big picture, you may get some helpful replies. /ravi PS: I've often fallen into this trap myself. When I ask someone how to do something, I invariably end up at a better solution by answering why I'd like to do this (i.e. what's the end result I'm trying to achieve).
My new year resolution: 2048 x 1536 Home | Articles | My .NET bits | Freeware ravib(at)ravib(dot)com