<?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 : getprintername() question</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 : getprintername() question]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Thu, 09 Apr 2026 14:40:22 +0000</pubDate>
  <lastBuildDate>Fri, 12 Nov 2010 14:35:15 +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=1623</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[getprintername() question : Yes, and it works fine if you...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7206.html#7206</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1433">quickpdf_learner</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 12 Nov 10 at 2:35PM<br /><br /><DIV>Yes, and it works fine if you define the printer as //printerservername/printername.</DIV><DIV>&nbsp;</DIV><DIV><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by Dimitry" alt="Originally posted by Dimitry" style="vertical-align: text-bottom;" /> <strong>Dimitry wrote:</strong><br /><br /></DIV><P>Glad to hear that you found the solution.</P><DIV></DIV>So using NewCustomPrinter() helped you with PrintDocument() on server 2008 IIS7?</td></tr></table> ]]>
   </description>
   <pubDate>Fri, 12 Nov 2010 14:35:15 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7206.html#7206</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : Glad to hear that you found the...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7184.html#7184</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1251">Dimitry</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 08 Nov 10 at 2:52PM<br /><br /><P>Glad to hear that you found the solution.</P><DIV></DIV>So using NewCustomPrinter() helped you with PrintDocument() on server 2008 IIS7?]]>
   </description>
   <pubDate>Mon, 08 Nov 2010 14:52:29 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7184.html#7184</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : Thank you, Dimitry.  I think...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7183.html#7183</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1433">quickpdf_learner</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 08 Nov 10 at 2:46PM<br /><br /><DIV>Thank you, Dimitry.</DIV><DIV>&nbsp;</DIV><DIV>I think I found a workaround. Since I am testing the same network printer on different servers, I use the long string&nbsp; "<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC" generated from server 2003 iis 6 and passed it to printdocument() method on server 2008 iis7, it did work fine!</SPAN></DIV><DIV><SPAN></SPAN>&nbsp;</DIV><DIV><SPAN></SPAN>&nbsp;</DIV><DIV><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by Dimitry" alt="Originally posted by Dimitry" style="vertical-align: text-bottom;" /> <strong>Dimitry wrote:</strong><br /><br /></DIV><DIV><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by quickpdf_learner" alt="Originally posted by quickpdf_learner" style="vertical-align: text-bottom;" /> <strong>quickpdf_learner wrote:</strong><br /><br />I&nbsp;have to&nbsp;bring up another question. How to use NewCustomPrinter(string printername)? </DIV><DIV>&nbsp;</DIV><DIV>For example, the printer name I want to use is <a href="file://%5C%5Cabc%5CIT%20HP%20M100" target="_blank">\\abc\IT HP M100</A>&nbsp;(I get it by using <FONT size=2>GetPrinterNames method)</FONT>, I get a long string like "<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC</SPAN>" after&nbsp;I pass it to the method.</DIV><DIV>&nbsp;</DIV><DIV>Any help is appreciated.</DIV></td></tr></table> <DIV></DIV><DIV>&nbsp;</DIV><DIV>NewCustomPrinter() returns a formal printer name that can be used with such functions as SetupCustomPrinter() and PrintDocument().</DIV><DIV>"<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC</SPAN>" - looks like a valid custom printer name.</DIV></td></tr></table> ]]>
   </description>
   <pubDate>Mon, 08 Nov 2010 14:46:54 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7183.html#7183</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question :   quickpdf_learner wrote:Ihave...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7182.html#7182</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1251">Dimitry</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 08 Nov 10 at 2:18PM<br /><br /><DIV><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by quickpdf_learner" alt="Originally posted by quickpdf_learner" style="vertical-align: text-bottom;" /> <strong>quickpdf_learner wrote:</strong><br /><br />I&nbsp;have to&nbsp;bring up another question. How to use NewCustomPrinter(string printername)? </DIV><DIV>&nbsp;</DIV><DIV>For example, the printer name I want to use is <a href="file://%5C%5Cabc%5CIT%20HP%20M100" target="_blank">\\abc\IT HP M100</A>&nbsp;(I get it by using <FONT size=2>GetPrinterNames method)</FONT>, I get a long string like "<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC</SPAN>" after&nbsp;I pass it to the method.</DIV><DIV>&nbsp;</DIV><DIV>Any help is appreciated.</DIV></td></tr></table> <DIV></DIV><DIV>&nbsp;</DIV><DIV>NewCustomPrinter() returns a formal printer name that can be used with such functions as SetupCustomPrinter() and PrintDocument().</DIV><DIV>"<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC</SPAN>" - looks like a valid custom printer name.</DIV><span style="font-size:10px"><br /><br />Edited by Dimitry - 08 Nov 10 at 2:18PM</span>]]>
   </description>
   <pubDate>Mon, 08 Nov 2010 14:18:11 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7182.html#7182</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : Some progress: This works for...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7171.html#7171</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1433">quickpdf_learner</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 04 Nov 10 at 8:56PM<br /><br /><DIV>Some progress:</DIV><DIV>This works for server 2003 with iis6, while still doesn't work for server 2008 with iis7.</DIV><DIV>&nbsp;</DIV><DIV>&nbsp;</DIV><DIV><table width="99%"><tr><td class="BBquote"><img src="forum_images/quote_box.png" title="Originally posted by quickpdf_learner" alt="Originally posted by quickpdf_learner" style="vertical-align: text-bottom;" /> <strong>quickpdf_learner wrote:</strong><br /><br />I&nbsp;have to&nbsp;bring up another question. How to use NewCustomPrinter(string printername)? </DIV><DIV>&nbsp;</DIV><DIV>For example, the printer name I want to use is <a href="file://%5C%5Cabc%5CIT%20HP%20M100" target="_blank">\\abc\IT HP M100</A>&nbsp;(I get it by using <FONT size=2>GetPrinterNames method)</FONT>, I get a long string like "<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC</SPAN>" after&nbsp;I pass it to the method.</DIV><DIV>&nbsp;</DIV><DIV>Any help is appreciated.</DIV></td></tr></table> ]]>
   </description>
   <pubDate>Thu, 04 Nov 2010 20:56:16 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7171.html#7171</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : Ihave tobring up another question....]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7169.html#7169</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1433">quickpdf_learner</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 04 Nov 10 at 4:20PM<br /><br />I&nbsp;have to&nbsp;bring up another question. How to use NewCustomPrinter(string printername)?<DIV>&nbsp;</DIV><DIV>For example, the printer name I want to use is <a href="file://%5C%5Cabc%5CIT%20HP%20M100" target="_blank">\\abc\IT HP M100</A>&nbsp;(I get it by using <FONT size=2>GetPrinterNames method)</FONT>, I get a long string like "<SPAN id=lblPrinterNames>F5C4BC4E2DA9D72F39144815BA862ABC</SPAN>" after&nbsp;I pass it to the method.</DIV><DIV>&nbsp;</DIV><DIV>Any help is appreciated.</DIV>]]>
   </description>
   <pubDate>Thu, 04 Nov 2010 16:20:43 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7169.html#7169</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : 1) local: windows 7 x86, web server:...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7159.html#7159</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1433">quickpdf_learner</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 03 Nov 10 at 12:42PM<br /><br />1) local: windows 7 x86, web server: windows 2008 x86 (error seen), windows 2003 x86 (return "Microsoft XPS Document Writer" as default printer which is not).<DIV>2) System language: English.</DIV><DIV>3) Library is loaded well cause other methods work fine.</DIV><DIV>&nbsp;</DIV><DIV>Thanks, I wll check as what Wheeley said.</DIV><DIV>&nbsp;</DIV>]]>
   </description>
   <pubDate>Wed, 03 Nov 2010 12:42:22 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7159.html#7159</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : GetDefaultPrinterName() should...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7153.html#7153</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1251">Dimitry</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 03 Nov 10 at 1:43AM<br /><br />GetDefaultPrinterName() should return default printer name and GetPrinterNames() - all installed printers.<BR>Can you please check the following positions: <BR>1. What version of Windows 2008 do you use: x86 or x64? <DIV>2. What is you system language?<BR>3. Please make sure that library is loaded and can be properly accessed. </DIV><DIV>For example&nbsp;try&nbsp;to simply check qp.LibraryVersion(). If this causes an error, make sure that you use proper library path.</DIV><DIV>&nbsp;</DIV><DIV>Hope to hear news from you soon.</DIV>]]>
   </description>
   <pubDate>Wed, 03 Nov 2010 01:43:57 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7153.html#7153</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : First, not knowing about how IIS...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7152.html#7152</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=121">Wheeley</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 02 Nov 10 at 10:46PM<br /><br />First, not knowing about how IIS is works, what I say next might be off base.&nbsp; So in case you don't know, printers are user specific. So 2 different users on the same computer can have different printers and defaults installed. The reason I mention this is because it sounds like the service is using a different user than whoever is logged onto the computer. So, if a service uses "local system account" as its log on option, their is now way to set the printers for this user. Setting the log on option for the service to a user will allow access to that user's printers. But to get the printers for the currently logged on user will require working on the privilidges I believe.<br><br>I hope this helps somehow. At least you will better understand how printers work with services.<br>Wheeley<br><img src="http://www.quickpdf.org/forum/smileys/smiley18.gif" border="0" alt="Ouch" title="Ouch" /><br>]]>
   </description>
   <pubDate>Tue, 02 Nov 2010 22:46:26 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7152.html#7152</guid>
  </item> 
  <item>
   <title><![CDATA[getprintername() question : I am trying to get the printer...]]></title>
   <link>http://www.quickpdf.org/forum/getprintername-question_topic1623_post7151.html#7151</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1433">quickpdf_learner</a><br /><strong>Subject:</strong> 1623<br /><strong>Posted:</strong> 02 Nov 10 at 7:28PM<br /><br />I am trying to get the printer name out of the web application and got different results.<DIV>My method is: </DIV><DIV><FONT color=#2b91af size=2><FONT color=#2b91af size=2><P>PDFLibrary</FONT></FONT><FONT size=2> qp = </FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>new</FONT></FONT><FONT size=2> </FONT><FONT color=#2b91af size=2><FONT color=#2b91af size=2>PDFLibrary</FONT></FONT><FONT size=2>(Server.MapPath(</FONT><FONT color=#a31515 size=2><FONT color=#a31515 size=2>"~\\QuickPDFDLL0721.dll"</FONT></FONT><FONT size=2>));</P><DIV><FONT color=#0000ff size=2><FONT color=#0000ff size=2><P>if</FONT></FONT><FONT size=2> (qp.LibraryLoaded())</P><P>{</P><P></FONT><FONT color=#008000 size=2><FONT color=#008000 size=2>// Check the license key</P></FONT></FONT><FONT size=2><P></FONT><FONT color=#0000ff size=2><FONT color=#0000ff size=2>if</FONT></FONT><FONT size=2> (qp.UnlockKey(</FONT><FONT color=#a31515 size=2><FONT color=#a31515 size=2>"XXXXXXXX"</FONT></FONT><FONT size=2>) == 1)</P><P>{</P></FONT></FONT></DIV><DIV>string pn = qp.<FONT color=#008000 size=2><FONT color=#008000 size=2>GetDefaultPrinterName();</FONT></FONT></DIV><DIV><FONT color=#008000 size=2></FONT>&nbsp;</DIV><DIV><FONT color=#008000 size=2>}</FONT></DIV><DIV><FONT color=#008000 size=2></FONT>&nbsp;</DIV></DIV><DIV><FONT color=#008000 size=2></FONT>&nbsp;</DIV><DIV>1) publish to local, everything is fine.</DIV><DIV>2) publish to web server (windows server 2003, iis6), only get "Microsoft XPS Document Writer" as the result.</DIV><DIV>3) publish to web server (windows server 2008, iis7), receive error message: "NullReferenceException: Object reference not set to an instance of an object.&#093;<BR>&nbsp;&nbsp; _Default.Page_Load(Object sender, EventArgs e) +229<BR>&nbsp;&nbsp; System.Web.Util.CalliHelper.EventArgFunctionCaller(IntPtr fp, Object o, Object t, EventArgs e) +14<BR>&nbsp;&nbsp; System.Web.Util.CalliEventHandlerDelegateProxy.Callback(Object sender, EventArgs e) +35<BR>&nbsp;&nbsp; System.Web.UI.Control.OnLoad(EventArgs e) +99<BR>&nbsp;&nbsp; System.Web.UI.Control.LoadRecursive() +50<BR>&nbsp;&nbsp; System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +627"</DIV><DIV>&nbsp;</DIV><DIV>Actually all the machines have the same default printer (which is not Microsoft XPS Document Writer).</DIV><DIV>&nbsp;</DIV><DIV>Forgive me if I am dumb, I already searched the forum and didn't find any same questions.</DIV><DIV>&nbsp;</DIV><DIV><BR>&nbsp;</DIV><DIV style="VISIBILITY: ">&nbsp;</DIV>]]>
   </description>
   <pubDate>Tue, 02 Nov 2010 19:28:34 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/getprintername-question_topic1623_post7151.html#7151</guid>
  </item> 
 </channel>
</rss>