In Win 7 64bit (and other 64bit OSes also probably) , the process I'm trying to kill is listed as "AppToKill.exe *32".
Following code works in 32bit XP but in Win7 64bit it doesn't kill it ...Tried adding *32 to the command but that didn't solve it.Code:Process P = new Process(); P.StartInfo = new ProcessStartInfo("cmd.exe", "/c taskkill /f /im AppToKill.exe"); P.StartInfo.WindowStyle = ProcessWindowStyle.Hidden; P.Start(); P.WaitForExit(); P.Close();
Any ideas ?




Reply With Quote