Skip Navigation LinksHome  /  Support  /  Forums  /  DynamicPDF PrintManager for .NET (v1.x)  /  Unhandled Exception

Forum Thread - Unhandled Exception

 Jul 29 2013 4:23 PM
I have been able to get the print manager to work well for the most part, but have come across an error that I can figure out how to handle correctly.  Here is a code snippet:

Basically I am calling RunWorkerAsync to print my document.  I get an exception that gets caught in bw_DoWork: Print job could not be created in the spooler. Error code:1722

There is also an unhandled exception that is not caught that causes my application to crash:
pplication: PrintService.exe
Framework Version: v4.0.30319
Description: The process was terminated due to an unhandled exception.
Exception Info: ceTe.DynamicPDF.Printing.PrintingException
   at k.d()
   at System.Threading.ThreadHelper.ThreadStart_Context(System.Object)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object, Boolean)
   at System.Threading.ExecutionContext.Run(System.Threading.ExecutionContext, System.Threading.ContextCallback, System.Object)
   at System.Threading.ThreadHelper.ThreadStart()

I would have expected this to get caught in the PrintJobFailed event, but it did not.

Here are my questions:  Where does that error code come from?  Is it a DynamicPDF error code or from Windows?  How can I handle the exception that I assume is happening withing the DynamicPDF library in an asynchronous process?

 Jul 30 2013 10:35 AM
Posted by a ceTe Software moderator

Is this error happening when a specific document is printed? If this is the case please email the PDF to

What is the version & build number of the PrintManager dll you are currently using?

ceTe Software Support Team.
 Jul 30 2013 12:22 PM
The error is not with a specific document, but with a specific printer.  I have tried different documents with the same error.  It is a network printer.  I am less concerned with why the error is happening ( I think it has to do with permissions for the printer).  I really just want to know how I can be sure to handle an exception like that if it occurs.  The problem is when it happens it crashes the service and it must be restarted manually.

DLL Version:
 Aug 01 2013 10:38 AM
Posted by a ceTe Software moderator

Thanks for the info, we are looking into it and will post an update soon.

ceTe Software Support Team.
 Sep 03 2013 4:56 PM
Posted by a ceTe Software moderator

This issue has been fixed in the latest version of PrintManager. Please email our support team at to obtain the new build.

ceTe Software Support Team.
 Oct 30 2013 8:20 PM
We started getting this error yesterday and have gotten it many times since with different pdf's. Can you offer any insight?
 Oct 31 2013 12:32 PM
Posted by a ceTe Software moderator

The latest build of PrintManager that contains the fix as per our last post was released on the website. If you are still evaluating, an evaluation edition can be downloaded here. If you have a license to use the latest version you can login to the customer area and download it there.

If you are already using the latest build and still seeing the error, please email us at with the following information.

1. Exception message including stack trace.
2. Code used.
3. Printer details

ceTe Software Support Team.
 Jun 27 2018 6:10 AM
I have a below dll reference in my .net solution[windows service] to print pdf to remote printer.

I noticed some weird issue with this dll. When printing a document to printer, service is getting crashed and need to restart it manually. No exceptions being recorded or caught.

It’s happening only with particular printer not the document. When passed the same document to anther network printer, its printing fine.

Please advise with this issue, let me know if you need any further details on this. Thanks in advance.


file version:
Product Version:
 Jun 29 2018 12:05 PM
Posted by a ceTe Software moderator

Please try using the latest DynamicPDF PrintManager for .NET product DLL file in your application and see if it works for you. You can download latest DynamicPDF PrintManager for .NET product installer from our website here. Install the latest product , remove reference for the older DLL file and reference the latest DLL file in your application.

ceTe Software Support Team.

All times are US Eastern Standard time. The time now is 6:00 AM.