Exemplo n.º 1
0
        private async void ButtonLoadPdf_Click(object sender, RoutedEventArgs e)
        {
            var Base64Data = await OpenAndConvert("9755___21107-8-1-MP10MP20-FEN.pdf");

            //var Base64Data = await OpenAndConvert2("compressed.tracemonkey-pldi-09.pdf");

            //var jsfunction = $"openPdfAsBase64('{Base64Data}')";
            //await sender.InvokeScriptAsync("eval", new[] { jsfunction });
            await PdfViewerControl.InvokeScriptAsync("openPdfAsBase64", new[] { Base64Data });

            //await PdfViewerControl.InvokeScriptAsync("eval", new[] { jsfunction });

            _pdfFileLoaded = true;
        }