//重启程序
string strAppFileName = Process.GetCurrentProcess().MainModule.FileName;
Process myNewProcess = new Process();
myNewProcess.StartInfo.FileName = strAppFileName;
myNewProcess.StartInfo.WorkingDirectory = AppDomain.CurrentDomain.BaseDirectory;
myNewProcess.Start();