- public static void CreatePDFx(string path)
- {
- PdfDocument outputDocumentx = new PdfDocument();
- }
- foreach (string pat_folder in pat_folders)
- {
- // Initially create PDFs
- Console.WriteLine("Watching this folder {0}", pat_folder);
- try
- {
- CreatePDFx(pat_folder);
- }
- catch (FileNotFoundException ex)
- {
- // Write error.
- System.IO.File.WriteAllLines(@"C:\filenotfound.txt", "Error");
- Console.WriteLine(ex);
- }
- }
C# - Pdfdocument - FileNotFound
Could anyone help me and tell me, why it always throw an exception? Any ideas? Thanks in advance!

Vivek KumarRank #272 · 9.3K reputationPosted Jan 18, 2019, 2:12 PM EST
Jenith ThakkarRank #789 · 2.9K reputationPosted Jan 18, 2019, 6:15 PM EST
Salman BegRank #284 · 8.8K reputationPosted Jan 20, 2019, 1:33 AM EST