private async void OnDetectCommandExecute() { _dialogService.ShowLoadingIndicator("Searching for the Chewsi Server in local network..."); var address = await _serviceDiscovery.Discover(); if (address != null) { DispatcherHelper.CheckBeginInvokeOnUI(() => { Host = Api.Common.Utils.GetHostFromAddress(address.Uri.ToString()); }); } else { _dialogService.Show("Server not found", "Completed", "Ok"); } _dialogService.HideLoadingIndicator(); }