You can do it by changing the group policy settings.
public void KillCtrlAltDelete()
{
RegistryKey regkey;
string keyValueInt = "1";
string subKey = "Software\Microsoft\Windows\CurrentVersion\Policies\System";
try
{
regkey = Registry.CurrentUser.CreateSubKey(subKey);
regkey.SetValue("DisableTaskMgr", keyValueInt);
regkey.Close();
}
catch (Exception ex)
{
MessageBox.Show(ex.ToString());
}
}
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…