Components for Developers
© 2000-2012, Two Pilots

PDF Library Download Features Manual Tutorials FAQ Pricing HTML2PDF-X Pilot History In the Lab

PDF Creator Pilot documentation

Download CHM version of this manual.
General document methods
Abort
Aborted
AddColorTransformationRule
AddImageFromBitmapHandle
AddImageFromBuffer
AddImageFromFile
AddImageFromFilename
AddImageFromMemory
AddImageWithColorMask
AddImageWithMask
AddTTFFontFromFile
AddTTFFontFromFile2
AddType1FontFromFile
AutoCreateURL
AutoLaunch
BeginDoc
BinaryImage
Compression
CreateWaterMark
CurrentWaterMarkIndex
DocumentInfo_Author
DocumentInfo_CreationDate
DocumentInfo_Creator
DocumentInfo_Keywords
DocumentInfo_Producer
DocumentInfo_Subject
DocumentInfo_Title
EndDoc
FileName
FlipImage
FontEmbedStyle
GenerateInMemoryFile
GetCurrentPageIndex
GetImageCount
GetImageHeight
GetImageResolution
GetImageWidth
GetUsedDC
GetUsedDCResolution
GlyphsToUnicodeStr
HDC
InitialZoom
InitialZoom2
JPEGQuality
LastError
LoadICCProfile
LogActionsAndErrors
LogTextOperation
MakeImageGrayScale
MakeImageNegative
MemoryFileSize
MetafileImagesCompressionType
MetafileImagesJpegCompression
NewPage
NonEmbeddedFonts
NonEmbeddedFonts_Add
NotEmbedAnyFonts
OnePass
OutputByteStream
OwnerPassword
PageCount
PageHeight
PageLayout
PageMode
PageNumber
PageWidth
PlaceImageToCurrentPage
PlayEMF
PrinterForVirtualDC
Printing
ProducePDFA
ProtectionEnabled
ProtectionKeyLength
ProtectionOptions_coAssembly
ProtectionOptions_coCopyInformation
ProtectionOptions_coExtractInfo
ProtectionOptions_coFillAnnotation
ProtectionOptions_coModifyAnnotation
ProtectionOptions_coModifyStructure
ProtectionOptions_coPrint
ProtectionOptions_coPrintHigh
Resolution
SetCurrentPage
SetPDFAOutputIntent
SetPDFXOutputIntent
StartEngine
SwitchedToWatermark
TransformColors
UseCurrentDocumentResolutionForNextPages
UserPassword
UseScreenDC
Version
ViewerPreferences_vpCenterWindow
ViewerPreferences_vpFitWindow
ViewerPreferences_vpHideMenuBar
ViewerPreferences_vpHideToolBar
ViewerPreferences_vpHideWindowUI
Collapse All

This method initializes processes for a new PDF document.

Syntax

HRESULT BeginDoc ()
Return value
If successful, this method returns S_OK. If it fails, this method should return one of the error values.

Remarks

The BeginDoc method initializes the creation of the PDF file and sets the current page to the first page of the PDF document.

Equivalent in new interface: None. When you want to create a new document, call theĀ IPDFDocument4::Clear method.

Example

Using of BeginDoc/EndDoc methods

Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.FileName := 'test.pdf';
PDF.Resolution := 96;
PDF.AutoLaunch := false;
{ set other options }

PDF.BeginDoc; { document creation started }
{ something else here... }
PDF.EndDoc; { document creation ended, document is saved to disk }
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->FileName = "test.pdf";
PDF->Resolution = 96;
PDF->AutoLaunch = false;
// set other options

PDF->BeginDoc(); // document creation started
// something else here...
PDF->EndDoc() // document creation ended, document is saved to disk
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.FileName = "test.pdf";
PDF.Resolution = 96;
PDF.AutoLaunch = false;
// set other options

PDF.BeginDoc(); // document creation started
// something else here...
PDF.EndDoc() // document creation ended, document is saved to disk
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created
PDF.FileName = "test.pdf"
PDF.Resolution = 96
PDF.AutoLaunch = False
' set other options

PDF.BeginDoc ' document creation started
' something else here...
PDF.EndDoc ' document creation ended, document is saved to disk

See Also

PDF Library Download Features Manual Tutorials FAQ Pricing HTML2PDF-X Pilot History In the Lab

 

 

PDF Library | Virtual Printer | Converters to PDF

Support | Blog | Forum | Contacts

© 2000-2012, Two Pilots