private async void print() { //var success = await Windows.System.Launcher.LaunchUriAsync(uri); try { LoaderText.Text = "Generando documento PDF..."; grdLoader.Visibility = Visibility.Visible; JsonObject result = await Finances.printCC(UserId); Uri uri = new Uri(result.GetNamedString("url")); string filename = result.GetNamedString("file_name"); StorageFile destinationFile = await DownloadsFolder.CreateFileAsync(filename, CreationCollisionOption.GenerateUniqueName); BackgroundDownloader downloader = new BackgroundDownloader(); DownloadOperation download = downloader.CreateDownload(uri, destinationFile); await HandleDownloadAsync(download, true); await Windows.System.Launcher.LaunchFileAsync(download.ResultFile); grdLoader.Visibility = Visibility.Collapsed; LoaderText.Text = ""; } catch (Exception ex) { var dialog = new MessageDialog(ex.Message); await dialog.ShowAsync(); } }