实现效果:
知识运用:
NoDispScrSavPage键值
实现代码:
private void radioButton2_Click(object sender, EventArgs e) { RegistryKey rk = Registry.CurrentUser.CreateSubKey(@"Software\Microsoft\Windows\CurrentVersion\Policies\System"); if (radioButton1.Checked == true) rk.SetValue("NoDispScrSavPage", 1, RegistryValueKind.DWord); else if (radioButton2.Checked == true) rk.SetValue("NoDispScrSavPage", 0, RegistryValueKind.DWord);} }