Table of Contents
- Getting Started
- EO.Pdf
- Overview
- Installation and Deployment
- Using HTML to PDF
- Using HTML to PDF
- Quick Start
- Setting Page Size and Margins
- Resizing Output
- Output Paging
- Web Page Authentication
- HTTP Post and Headers
- JavaScript in HTML
- Conversion Trigger
- Links in HTML
- Page Header and Footer
- Partial Page Conversion
- Repeating Table Header and Footer
- Merging Multiple HTML pages
- Generating Page Images
- Using with PDF Creator
- Creating Interactive Form Elements
- Working with Secure Pages
- Using HtmlToPdfSession object
- Troubleshooting HTML to PDF
- Debugging HTML to PDF
- Using PDF Creator
- Working with Existing PDF Files
- Using in Web Application
- Advanced Topics
- EO.Web
- EO.WebBrowser
- EO.Wpf
- Common Topics
- Reference
Debugging HTML to PDF |
You can use the built-in JavaScript debug console or developer tools to debug the page you are trying to convert.
Using JavaScript Debug Console
JavaScript debug console captures debug message output from your JavaScript code. See here for more information on how to use this feature.
Using Developer Tools
Internally EO.Pdf uses the same Chromium browser engine from EO.WebBrowser, so it can utilize advanced debug feature such as the built-in Developer Tools provided by EO.WebBrowser. The following code demonstrates how to start the built-in debug UI.
//Display the developer tools UI EO.WebBrowser.WebView.ShowDebugUI(); //Set the trigger mode to manual so that the converter //will not convert the page immediately after the page //has been loaded, this is necessary because otherwise //we would not have time to debug HtmlToPdf.Options.TriggerMode = HtmlToPdfTriggerMode.Manual; //Set the conversion time out value to a large value. //This is necessary so that the conversion won't time //out while we are debugging the page HtmlToPdf.Options.MaxLoadWaitTime = 1000000; //Start the converter HtmlToPdf.ConvertUrl("http://www.google.com", result_pdf_file);
Once the debug UI is displayed, please follow the steps here on how to use the debug UI.