84 references to SR
System.ServiceProcess.ServiceController (84)
System\ServiceProcess\ServiceBase.cs (41)
67throw new InvalidOperationException(SR.NotInPendingState); 132throw new InvalidOperationException(SR.CannotChangeProperties); 158throw new InvalidOperationException(SR.CannotChangeProperties); 184throw new InvalidOperationException(SR.CannotChangeProperties); 210throw new InvalidOperationException(SR.CannotChangeProperties); 236throw new InvalidOperationException(SR.CannotChangeProperties); 281throw new InvalidOperationException(SR.CannotChangeName); 285throw new ArgumentException(SR.Format(SR.ServiceName, value, ServiceBase.MaxNameLength.ToString(CultureInfo.CurrentCulture))); 400WriteLogEntry(SR.ContinueSuccessful); 406WriteLogEntry(SR.Format(SR.ContinueFailed, e), EventLogEntryType.Error); 424WriteLogEntry(SR.CommandSuccessful); 428WriteLogEntry(SR.Format(SR.CommandFailed, e), EventLogEntryType.Error); 443WriteLogEntry(SR.PauseSuccessful); 449WriteLogEntry(SR.Format(SR.PauseFailed, e), EventLogEntryType.Error); 472WriteLogEntry(SR.PowerEventOK); 476WriteLogEntry(SR.Format(SR.PowerEventFailed, e), EventLogEntryType.Error); 492WriteLogEntry(SR.Format(SR.SessionChangeFailed, e), EventLogEntryType.Error); 521WriteLogEntry(SR.StopSuccessful); 529WriteLogEntry(SR.Format(SR.StopFailed, e), EventLogEntryType.Error); 542WriteLogEntry(SR.ShutdownOK); 560WriteLogEntry(SR.Format(SR.ShutdownFailed, e), EventLogEntryType.Error); 582throw new ArgumentException(SR.NoServices); 620Console.WriteLine(SR.CantStartFromCommandLine); 628service.WriteLogEntry(SR.Format(SR.StartFailed, errorMessage), EventLogEntryType.Error); 654throw new ArgumentException(SR.NoServices); 827WriteLogEntry(SR.StartSuccessful); 834WriteLogEntry(SR.Format(SR.StartFailed, e), EventLogEntryType.Error); 892WriteLogEntry(SR.Format(SR.StartFailed, errorMessage), EventLogEntryType.Error); 936WriteLogEntry(SR.Format(SR.StartFailed, errorMessage), EventLogEntryType.Error);
System\ServiceProcess\ServiceController.cs (43)
66throw new ArgumentException(SR.Format(SR.BadMachineName, machineName)); 71throw new ArgumentException(SR.Format(SR.InvalidParameter, nameof(name), name), nameof(name)); 82throw new ArgumentException(SR.Format(SR.BadMachineName, machineName)); 101throw new ArgumentException(SR.Format(SR.BadMachineName, machineName)); 246throw new ArgumentException(SR.Format(SR.BadMachineName, value)); 286throw new ArgumentException(SR.Format(SR.ServiceName, value, ServiceBase.MaxNameLength.ToString())); 523throw new InvalidOperationException(SR.Format(SR.ServiceName, userGivenName, ServiceBase.MaxNameLength.ToString())); 542throw new InvalidOperationException(SR.Format(SR.NoService, userGivenName, _machineName), new Win32Exception(Interop.Errors.ERROR_SERVICE_DOES_NOT_EXIST)); 556throw new InvalidOperationException(SR.Format(SR.NoService, _name, _machineName), new Win32Exception(Interop.Errors.ERROR_SERVICE_DOES_NOT_EXIST)); 589throw new InvalidOperationException(SR.Format(SR.NoService, serviceDisplayName, _machineName), new Win32Exception(lastError)); 619throw new InvalidOperationException(SR.Format(SR.NoService, serviceName, _machineName), new Win32Exception(lastError)); 640throw new InvalidOperationException(SR.Format(SR.OpenSC, machineName), inner); 691throw new InvalidOperationException(SR.Format(SR.OpenService, ServiceName, _machineName), inner); 736throw new ArgumentException(SR.Format(SR.BadMachineName, machineName)); 812throw new InvalidOperationException(SR.Format(SR.PauseService, ServiceName, _machineName), inner); 827throw new InvalidOperationException(SR.Format(SR.ResumeService, ServiceName, _machineName), inner); 843throw new InvalidOperationException(SR.Format(SR.ControlService, ServiceName, MachineName), inner); 881throw new ArgumentNullException($"{nameof(args)}[{i}]", SR.ArgsCantBeNull); 901throw new InvalidOperationException(SR.Format(SR.CannotStart, ServiceName, _machineName), inner); 962throw new InvalidOperationException(SR.Format(SR.StopService, ServiceName, _machineName), inner); 983throw new ArgumentException(SR.Format(SR.InvalidEnumArgument, nameof(desiredStatus), (int)desiredStatus, typeof(ServiceControllerStatus))); 990throw new System.ServiceProcess.TimeoutException(SR.Format(SR.Timeout, ServiceName));