PDF Xpress provides the ability to control the level of information written to the debug log, as well as the ability to turn off writing to a debug log file completely.
Control Debugging Information
Use the methods and properties below to adjust the settings of your debugging for optimal performance.
-
To generate a debug log file, set Debug to true.
-
The log file is kept at the location specified by DebugLogFile.
-
Set the ErrorLevel to Development or Detailed to indicate the level of detail logged.
C# Example | Copy Code |
---|---|
// This code demonstrates turning on the debug log and specifying the error level as well as the location that the log file is written to Accusoft.PdfXpressSdk.PdfXpress pdfXpress1 = null; try { pdfXpress1 = new PdfXpress(); pdfXpress1.Initialize(null, null); pdfXpress1.Debug = true; pdfXpress1.DebugLogFile = "C:\\pdfxpress.log"; pdfXpress1.ErrorLevel = ErrorLevel.Detailed; } catch (System.Exception ex) { } finally { if ( null != pdfXpress1 ) pdfXpress1.Dispose( ); } |
When rendering an image at a high resolution, a "Creation of rasterizer port failed" exception may occur. If this exception occurs, lower the resolution and attempt to render the page again. |