C# Start/Stop Windows Update
//START
try
{
ServiceController sc = new ServiceController("wuauserv");
sc.Start();
}
catch (Exception ex)
{
MessageBox.Show("service could not be started because of the following _error_:\r\n" + ex);
}
//STOP
try
{
ServiceController sc = new ServiceController("wuauserv");
sc.Stop();
}
catch (Exception ex)
{
MessageBox.Show("service could not be stopped because of the following _error_:\r\n" + ex);
}