diff --git a/WGneu/Print/Pdf.cs b/WGneu/Print/Pdf.cs index 9cad37b..ef5caae 100644 --- a/WGneu/Print/Pdf.cs +++ b/WGneu/Print/Pdf.cs @@ -30,5 +30,12 @@ namespace WGneu.Print { await page.WaitForFunctionAsync("() => window.finished"); await page.PdfAsync(path_pdf); } + + public static void Display(string path) { + Process.Start(new ProcessStartInfo() { + FileName = path, + UseShellExecute = true, + }); + } } } diff --git a/WGneu/Print/Template.cs b/WGneu/Print/Template.cs index 4ce9893..5839466 100644 --- a/WGneu/Print/Template.cs +++ b/WGneu/Print/Template.cs @@ -12,10 +12,7 @@ namespace WGneu.Print { public static async void Test() { await Pdf.Convert(ROOT + "din-5008.html", ROOT + "test.pdf"); - Process.Start(new ProcessStartInfo() { - FileName = ROOT + "test.pdf", - UseShellExecute = true, - }); + Pdf.Display(ROOT + "test.pdf"); } } } diff --git a/WGneu/Windows/MemberListWindow.xaml b/WGneu/Windows/MemberListWindow.xaml index c42ead9..107f1f9 100644 --- a/WGneu/Windows/MemberListWindow.xaml +++ b/WGneu/Windows/MemberListWindow.xaml @@ -75,7 +75,8 @@ -