async Task GetImageDetailsAsync(MediaFile image) { try { if (image == null) { return; } IsBusy = true; _dialogService.ShowLoading("Analysing Image..."); selectedImage.Source = ImageSource.FromFile(image.Path); var analysis = await _cognitiveService.GetImageDetailsAsync(image.GetStream()); titleLabel.Text = string.Join(Environment.NewLine, analysis.Description.Captions.Select(x => x.Text)); descLabel.Text = string.Join(", ", analysis.Tags.Select(x => x.Name)); _dialogService.HideLoading(); } finally { IsBusy = false; _dialogService.HideLoading(); } }