<?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 : DPLLoadFromString Fails</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 : Sample Code : DPLLoadFromString Fails]]></description>
  <copyright>Copyright (c) 2006-2013 Web Wiz Forums - All Rights Reserved.</copyright>
  <pubDate>Mon, 11 May 2026 22:23:20 +0000</pubDate>
  <lastBuildDate>Thu, 24 Jan 2013 17:01:42 +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=2511</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[DPLLoadFromString Fails : Thank you very much! It now works....]]></title>
   <link>http://www.quickpdf.org/forum/dplloadfromstring-fails_topic2511_post10443.html#10443</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=2163">Xan</a><br /><strong>Subject:</strong> 2511<br /><strong>Posted:</strong> 24 Jan 13 at 5:01PM<br /><br />Thank you very much!&nbsp; It now works.&nbsp; Here's the C++ version, in case anybody stumbles across this.<br><br><table width="99%"><tr><td><pre class="BBcode"><br>char * buffer = DPLCreateBuffer(InstanceID, decoded_content.length());<br>if(buffer == 0)<br>{ return "Unable to create buffer"; }<br>DPLAddToBuffer(InstanceID, buffer, const_cast&lt;char *&gt;(decoded_content.c_str()), decoded_content.length());<br>if(DPLLoadFromString(InstanceID, buffer, L"") == 0)<br>{<br>&nbsp;&nbsp;&nbsp; DPLReleaseBuffer(InstanceID, buffer);<br>&nbsp;&nbsp;&nbsp; return "Unable to load PDF";<br>}<br>DPLReleaseBuffer(InstanceID, buffer);<br></pre></td></tr></table><br>]]>
   </description>
   <pubDate>Thu, 24 Jan 2013 17:01:42 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/dplloadfromstring-fails_topic2511_post10443.html#10443</guid>
  </item> 
  <item>
   <title><![CDATA[DPLLoadFromString Fails : I see you are using C++. The word...]]></title>
   <link>http://www.quickpdf.org/forum/dplloadfromstring-fails_topic2511_post10441.html#10441</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=1483">AndrewC</a><br /><strong>Subject:</strong> 2511<br /><strong>Posted:</strong> 24 Jan 13 at 7:00AM<br /><br />I see you are using C++. &nbsp;The word string is a little confusing as it actually refers to a Delphi AnsiString which is a little different to a char pointer.<div><br></div><div>I suggest you read the final comment in the following thread. &nbsp;It shows how to create an AnsiString buffer which can be used with LoadFromString.</div><div><br></div><div>http://www.quickpdf.org/forum/using-qpl8xx-with-realbasic-realstudio_topic2315.html<br><br><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">int BufferID , Test , ImageID;</span></div><div><br style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">BufferID = QPDFCreateBuffer ( InstanceID , buffer.Size )</span><br style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">if (BufferID != 0) &nbsp;// OK</span></div><div>{<br style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">&nbsp; &nbsp; Test = QPDFAddToBuffer (InstanceID , BufferID , buf, sizeof(buf));</span><br style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><br></span></div><div><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">&nbsp; &nbsp; QPDFLoadFromFromString (InstanceID,&nbsp; BufferID , ""</span><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">);</span><br style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;"><br></span></div><div><span style=": rgb251, 251, 253; font-family: Verdana, 'Helvetica Neue', Helvetica, Arial, sans-serif; font-size: 14px; line-height: normal;">&nbsp; &nbsp; Test = QPDFReleaseBuffer ( InstanceID,&nbsp; BufferID )</span></div><div><span style="line-height: 1.4;">}</span></div><div><br></div><span style="font-size:10px"><br /><br />Edited by AndrewC - 13 Mar 14 at 12:09AM</span>]]>
   </description>
   <pubDate>Thu, 24 Jan 2013 07:00:22 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/dplloadfromstring-fails_topic2511_post10441.html#10441</guid>
  </item> 
  <item>
   <title><![CDATA[DPLLoadFromString Fails : Hello,I&amp;#039;m using QuickPDF...]]></title>
   <link>http://www.quickpdf.org/forum/dplloadfromstring-fails_topic2511_post10438.html#10438</link>
   <description>
    <![CDATA[<strong>Author:</strong> <a href="http://www.quickpdf.org/forum/member_profile.asp?PF=2163">Xan</a><br /><strong>Subject:</strong> 2511<br /><strong>Posted:</strong> 23 Jan 13 at 11:11PM<br /><br />Hello,<br><br>I'm using QuickPDF Library as a LIB, building a DLL to be a browser plugin.&nbsp; It works great overall.&nbsp; Right now, I'm taking in a Base64-encoded PDF as input, decoding it, writing that file to a temporary file, and then loading that with DPLLoadFromFile.<br><br>It would be really nice to use DPLLoadFromString, since I have a std::string containing the Base64-decoded data, but I can't get it to work.&nbsp; The call to DPLLoadFromString always returns 0.<br><br>I've tried several machinations, but here's what I believe ought to work.&nbsp; Can anybody help?<br><table width="99%"><tr><td><pre class="BBcode">DPLLoadFromString(InstanceID, const_cast&lt;char *&gt;(decoded_content.c_str()), L"");</pre></td></tr></table><br><br><br><br>]]>
   </description>
   <pubDate>Wed, 23 Jan 2013 23:11:57 +0000</pubDate>
   <guid isPermaLink="true">http://www.quickpdf.org/forum/dplloadfromstring-fails_topic2511_post10438.html#10438</guid>
  </item> 
 </channel>
</rss>