<?xml version="1.0" encoding="utf-8" ?>
<?xml-stylesheet type="text/xsl" href="RSS_xslt_style.asp" version="1.0" ?>
<rss version="2.0" xmlns:WebWizForums="http://syndication.webwiz.co.uk/rss_namespace/">
 <channel>
  <title>Debenu Quick PDF Library - PDF SDK Community Forum : PrintDocument() crashing application</title>
  <link>http://www.quickpdf.org/forum/</link>
  <description><![CDATA[This is an XML content feed of; Debenu Quick PDF Library - PDF SDK Community Forum : I need help - I can help : PrintDocument() crashing application]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Wed, 22 Jul 2026 20:45:00 +0000</pubDate>
  <lastBuildDate>Fri, 09 Oct 2009 12:08:48 +0000</lastBuildDate>
  <docs>http://blogs.law.harvard.edu/tech/rss</docs>
  <generator>Web Wiz Forums 11.01</generator>
  <ttl>360</ttl>
  <WebWizForums:feedURL>www.quickpdf.org/forum/RSS_post_feed.asp?TID=1233</WebWizForums:feedURL>
  <image>
   <title><![CDATA[Debenu Quick PDF Library - PDF SDK Community Forum]]></title>
   <url>http://www.quickpdf.org/forum/forum_images/QPDF_Forum_Title.png</url>
   <link>http://www.quickpdf.org/forum/</link>
  </image>
  <item>
   <title><![CDATA[PrintDocument() crashing application : Hello again,I have just downloaded...]]></title>
   <link>http://www.quickpdf.org/forum/printdocument-crashing-application_topic1233_post5655.html#5655</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1170">stakon</a><br /><strong>Subject:</strong> 1233<br /><strong>Posted:</strong> 09 Oct 09 at 12:08PM<br /><br />Hello again,<br><br>I have just downloaded your demo, it looks very nice.<br>It helped me resolve the error.I found what caused it:<br><br>When calling <b>QP.GetPrinterNames()</b> the Printer names are separated by commas <b>and</b> each one is within quotes "".<br>So in my above example the string tokens are within quotes.I will trimm my string from the "" and hope everything runs smoothly.<br><br>Stakon.<br><br>]]>
   </description>
   <pubDate>Fri, 09 Oct 2009 12:08:48 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/printdocument-crashing-application_topic1233_post5655.html#5655</guid>
  </item> 
  <item>
   <title><![CDATA[PrintDocument() crashing application : Hi Stakon!Is the content of customPrinterName...]]></title>
   <link>http://www.quickpdf.org/forum/printdocument-crashing-application_topic1233_post5654.html#5654</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=111">Ingo</a><br /><strong>Subject:</strong> 1233<br /><strong>Posted:</strong> 09 Oct 09 at 10:46AM<br /><br />Hi Stakon!<br><br>Is the content of customPrinterName correct?<br>Is the content identical to the printer in your system?<br>BTW: There's a good sample for you in the brandnew "QuickPDF library demo" Rowan talked about in the general section here. Try it.<br><br>Cheers and welcome here,<br>Ingo<br><br>]]>
   </description>
   <pubDate>Fri, 09 Oct 2009 10:46:33 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/printdocument-crashing-application_topic1233_post5654.html#5654</guid>
  </item> 
  <item>
   <title><![CDATA[PrintDocument() crashing application : Good day,I have recently started...]]></title>
   <link>http://www.quickpdf.org/forum/printdocument-crashing-application_topic1233_post5653.html#5653</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1170">stakon</a><br /><strong>Subject:</strong> 1233<br /><strong>Posted:</strong> 09 Oct 09 at 10:02AM<br /><br />Good day,<br><br>I have recently started to use your QuickPDF dll for C++.<br>I find it very friendly and contains most things i will need.<br><br>Although most features run smoothly, unfortunately i have encountered the following problem:<br>When using <b>PrintDocument()</b> my program crashes when trying to execute:<br><br><b>result = QuickPDFPrintDocument(instanceID, sp1, StartPage, EndPage,Options);</b><br>which is located in the <b>QuickPDFDLL0715.cpp</b> file.<br><br>Here is my code before invoking <b>PrintDocument():<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; </b>int res;<font color="#009933">//check var for returned results</font><br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; std::string selectedPrinter;<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; std::string printerNames = QP.GetPrinterNames();//Printers in string seperated by comma<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; std::string token;<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; std::istringstream iss(printerNames);<br><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; while ( getline(iss, token, ',') )<font color="#009933">//tokenize and get firsst printer</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; {<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; selectedPrinter = token;<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; break;<font color="#009933">//only take the 1st printer</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; }<br><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; std::string customPrinterName;<br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; customPrinterName = QP.NewCustomPrinter(selectedPrinter);/<font color="#009933">/create new custom printer from the one we selected</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;<font color="#009933"> //Setup various values of the printer...</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; res = QP.SetupCustomPrinter(customPrinterName,6,1);<font color="#009933">//Color = monochrome</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; res = QP.SetupCustomPrinter(customPrinterName,11,2);<font color="#009933">//Orientation = landscape</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; <font color="#009933">//Setup varous print options</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; int printOptions = QP.PrintOptions(0,0,"Custom Title of document");<font color="#009933">//scaling,rotation,title</font><br>&nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp; QP.PrintDocument(customPrinterName,1,2,printOptions);<font color="#009933">//print the pages within this range</font><b><br><font color="#cc0000">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; ***HERE THE PROGRAM CRASHES***<br></font></b><font color="#cc0000"><font color="#000000"><br>Note that all the above arguments are<font color="#cc0000"> <font color="#000000">checked and all "res" values return success. <br>Any ideas?<br><br>Thanx in advance,<br><br>Stakon.<br></font></font></font></font><b><font color="#cc0000"><br></font><br></b>]]>
   </description>
   <pubDate>Fri, 09 Oct 2009 10:02:58 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/printdocument-crashing-application_topic1233_post5653.html#5653</guid>
  </item> 
 </channel>
</rss>