Do you own a Debenu Quick PDF Library version 7, 8, 9, 10, 11, 12, 13 or iSEDQuickPDF license? Upgrade to Debenu Quick PDF Library 14 today!

Debenu Quick PDF Library - PDF SDK Community Forum Homepage
Forum Home Forum Home > For Users of the Library > I need help - I can help
  New Posts New Posts RSS Feed - Problems with Delphi RIO and QuickPDF Lite
  FAQ FAQ  Forum Search   Register Register  Login Login

Problems with Delphi RIO and QuickPDF Lite

 Post Reply Post Reply
Author
Message
Jonno-UK View Drop Down
Beginner
Beginner


Joined: 29 Aug 19
Location: London
Status: Offline
Points: 2
Post Options Post Options   Thanks (0) Thanks(0)   Quote Jonno-UK Quote  Post ReplyReply Direct Link To This Post Topic: Problems with Delphi RIO and QuickPDF Lite
    Posted: 29 Aug 19 at 3:30PM
Hi,
I have a Delphi FMX project and I wish to create some very simple PDF files.
I have downloaded QuickPDF Lite, installed it, imported the type library and installed the package.
(This generated the DebenuPDFLibraryAX1411_TLB file)

My code is as follows :
var
   PDF_library : OleVariant;

begin
    PDF_library:=CreateOleObject('DebenuPDFLibraryAX1411.PDFLibrary');

    PDF_library.SetMeasurementUnits(1);  { 1 = mm  2 = inches }
    PDF_library.SetPageSize('A4');
 
{ At this point I can see that PageWidth and PageHeight are 210/297 - which looks great }

    PDF_library.DrawText(100,500,'Hello world');  { I am aware that the co-ordinates might be out of range, but this should not be a problem }
    PDF_library.SaveToFile('C:\TestDocs\Test.pdf');
end;

Yet the code above never creates a pdf file in the TestDocs folder.
What am I doing wrong?
I am sorry but I am new to this.

Thanks in advance. 




Edited by Jonno-UK - 29 Aug 19 at 3:46PM
Back to Top
tfrost View Drop Down
Senior Member
Senior Member


Joined: 06 Sep 10
Location: UK
Status: Offline
Points: 232
Post Options Post Options   Thanks (0) Thanks(0)   Quote tfrost Quote  Post ReplyReply Direct Link To This Post Posted: 29 Aug 19 at 8:01PM
Warning: I have never used the ActiveX interface or the Lite edition, and my applications typically work with existing PDFs, not creating new ones.  But my immediate suggestion would be to check if SaveToFile returns a 0, and if so call GetLastError. 

In addition, I think you need to call New Document and SelectPage (there may be one created with a new document, I can't remember; if not then NewPage), before you can draw text onto it.  Perhaps the Error value would tell you this.  Someone else may be more helpful but this is a start.  Persevere, it will all come together quite soon!  And the users here are friendly; we were all new once.  The example scripts are also very helpful.
Back to Top
Ingo View Drop Down
Moderator Group
Moderator Group
Avatar

Joined: 29 Oct 05
Status: Offline
Points: 2998
Post Options Post Options   Thanks (0) Thanks(0)   Quote Ingo Quote  Post ReplyReply Direct Link To This Post Posted: 29 Aug 19 at 10:20PM
Hi Jonno,

retry again and start with this sample from Rowan (one of the publishers):
http://www.quickpdf.org/forum/getting-started-with-quickpdf-lite_topic1612.html

Cheers and welcome here,
Ingo

Cheers,
Ingo

Back to Top
 Post Reply Post Reply
  Share Topic   

Forum Jump Forum Permissions View Drop Down

Forum Software by Web Wiz Forums® version 11.01
Copyright ©2001-2014 Web Wiz Ltd.

Copyright © 2017 Debenu. Debenu Quick PDF Library is a PDF SDK. All rights reserved. AboutContactBlogSupportOnline Store