void _serverControlStrip_StartAllServers(object sender, EventArgs e) { Gateways gateways = (Gateways)_gatewaySource.DataSource; foreach (Gateways.GatewayServerRow gateway in gateways.GatewayServer) { DicomService service = GetGatewayService(gateway); if (null != service && service.Status != ServiceControllerStatus.Running) { service.Start( ); } } }
void _serverControlStrip_StartServer(object sender, EventArgs e) { DicomService gatewayService = null; gatewayService = GetCurrentDicomService( ); if (gatewayService != null) { if (gatewayService.Status != ServiceControllerStatus.Running) { gatewayService.Start( ); } } }