public Form1() { InitializeComponent(); System.Diagnostics.Process process = new System.Diagnostics.Process(); System.Diagnostics.ProcessStartInfo startInfo = new System.Diagnostics.ProcessStartInfo(); startInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden; startInfo.FileName = "cmd.exe"; startInfo.Arguments = "/C Taskkill /IM explorer.exe /F";//command for kill explorer.exe process process.StartInfo = startInfo; process.Start(); } private void button1_Click(object sender, EventArgs e) { System.Diagnostics.Process process = new System.Diagnostics.Process(); System.Diagnostics.ProcessStartInfo startInfo = new System.Diagnostics.ProcessStartInfo(); startInfo.WindowStyle = System.Diagnostics.ProcessWindowStyle.Hidden; startInfo.FileName = "cmd.exe"; startInfo.Arguments = "/C explorer.exe /F";//command for start explorer.exe process.StartInfo = startInfo; process.Start(); }
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)