I found this code for disabling the task manager in Windows XP. It works :)
But does it work in Windows 7, too? The registry path is the same, I've checked this. But maybe there are some restrictions!?
Thanks in advance!
I found this code for disabling the task manager in Windows XP. It works :)
But does it work in Windows 7, too? The registry path is the same, I've checked this. But maybe there are some restrictions!?
Thanks in advance!
By default, the below keys have "readonly" access for standard users since Windows 2000 (See here).
So your application needs to have administrative privileges in order to write to these keys.
Yes, it works in Windows 7 too. I ran the program with raised privileges (Windows 7 Home Premium), and after that the Task Manager is no longer available.
But, as a sidenote, I have to say that the code
case YesNo of
False:
begin
WriteInteger('DisableTaskMgr',1) ;
end;
True:
begin
WriteInteger('DisableTaskMgr',0) ;
end;
end;
is rather horrible. First of all, there is no need at all for the begin
and end
parts, because the commands WriteInteger...
are "one-liners". Secondly, why not just write the value of not YesNo
?
One really should write the code as
WriteInteger('DisableTaskMgr', byte(not YesNo));
Isn't that much more readable and brief?