Is it possible to restart IIS7 using C#? If so, how?
+1
A:
Just execute the command-line option using System.Diagnostics.Process.Start();
Henri
2009-08-22 09:59:16
+4
A:
System.Diagnostics.Process.Start(@"C:\windows\system32\iisreset.exe");
should do the trick :)
Dan
Daniel Elliott
2009-08-22 10:02:20
Probably should use environment variable for windows path though :)
Daniel Elliott
2009-08-22 10:02:55