Sending PDF to printer

Sending PDF to printer

Forum member · Sep 11, 2010
Hi, Is there a function to send the generated .pdf file to printer? Thanks Bert

Re: Sending PDF to printer

Support · Sep 13, 2010
Hello Bert, There is no such functionality in our v3.0 product. You may try using the Ghostscript Site to accomplish your printing needs. However in our latest version of DynamicPDF Generator for NET we have added the functionality to add JavaScript to the document. Using the JavaScript you can force the document to be printed directly to the default printer without using the print preview. But the document would need to be output to the web for the JavaScript action to be triggered. Feel free to download fully functional evaluation version from our web site . Sample Code: ceTe.DynamicPDF.Document document = new ceTe.DynamicPDF.Document(); ceTe.DynamicPDF.Page page = new ceTe.DynamicPDF.Page( PageSize.Letter, PageOrientation.Portrait, 54.0f ); string text = "Hello ASPX C# World...\nFrom DynamicPDF™ Generator for NET\nDynamicPDF.com"; Label label = new Label( text, 0, 0, 504, 100, Font.Helvetica, 18, TextAlign.Center ); DocumentJavaScript javaScript = new DocumentJavaScript( "Test", "this.print({bUI: false, bSilent: true, bShrinkToFit: true});" ); document.JavaScripts.Add( javaScript ); page.Elements.Add( label ); document.Pages.Add( page ); document.DrawToWeb( "HelloWorld.pdf" ); You can also use one of our products DynamicPDF PrintManager for printing PDF documents programmatically. Please feel free to download the fully functional evaluation version of our product DynamicPDF PrintManager from our website . Thanks, ceTe Software Support Team.