Two Pilots™    Home  |  Navigation  |  Site Map  |  Products  |  Download  |  Prices  |  For Partners  |  Support


All forums · Statistics · Search ·

Two Pilots forum / For software developers / Page Orientation in PDF Creator Pilot
Author Message
rraines
# Posted: 24 Oct 2007 17:37


I have a printout that works fine in portrait orientation but I can't get it to printout in landscape orientation. I have tried the following code:

MyPDF = New PDFCreatorPilot2.piPDFDocument
MyPDF.PDFPAGE_Size = TxPDFPageSize.ps8x11
MyPDF.PDFPAGE_Orientation = TxPDFPageOrientation.poPageLandscape


MyPDF.PDFPAGE_SetActiveFont("Courier New", True, False, False, False, HEADER_FONT_SIZE, 0)

MyPDF.PDFPAGE_TextOut(MARGIN, intRowCount * ROW_HEIGHT, TxPageOrientation.poLandscape, strFirstLine)

Any ideas how to make this work?

Thanks

Stanislav
Member
# Posted: 25 Oct 2007 00:38


Hello,

Here is an example of landscape orientation output in VBScript:

' create pdf library object
Set PDF = CreateObject("PDFCreatorPilot3.PDFDocument3")

' initialize PDF Engine
PDF.StartEngine "demo@demo", "demo"

' Set AutoLaunch property to TRUE to automatically launch PDF Reader
PDF.AutoLaunch = true
PDF.FileName = "HelloPDF.pdf"
' set document title
PDF.DocumentInfo_Title = "Hello, PDF! (PDF Creator Pilot Demo)"

' start document generation
PDF.BeginDoc

PDF.PDFPAGE_Orientation = 1

' draw "HELLO, PDF" message on the current PDF page
PDF.PDFPAGE_SetActiveFont "Verdana", True, False, False, False, 14, 0
PDF.PDFPAGE_TextOut 10, 20, 0, "HELLO, PDF!"

' finalize document generation
PDF.EndDoc

' disconnect from library
Set PDF = Nothing

Best regards,
Stanislav
Two Pilots
www.colorpilot.com

 

 

Powered by miniBB 2.0 RC7 © 2001-2004 Page creation time (sec.): 0.013

 

Page top