Xojo Developer Conference
25/27th April 2018 in Denver.
MBS Xojo Conference
6/7th September 2018 in Munich, Germany.

DynaPDF Manual - Page 313

Previous Page 312   Index   Next Page 314

Function Reference
Page 313 of 750
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
FlushPageContent
Syntax:
SI32 pdfFlushPageContent(
const PPDF* IPDF,
// Instance pointer
struct TPDFStack* Stack) // Operation stack
The function replaces the content stream of a page or template that was changed with the function
ReplacePageText() or ReplacePageTextEx() beforehand.
The function must be called after all changes are made. See GetPageText() for an example
application.
Return values:
If the function succeeds the return value is 1. If the function fails the return value is 0.
FlushPages
Syntax:
LBOOL pdfFlushPages(
const PPDF* IPDF,
// Instance pointer
TFlushPageFlags Flags) // see below
typedef enum
{
fpfDefault
= 0, // Write anything to the file that is possible
fpfImagesOnly
= 1, // If set, only images are written to the PDF
// file. All pages are still kept in memory and
// can be modified with EditPage(). Flushed images
// can still be referenced in other pages. The
// image handles remain valid.
fpfExclLastPage = 2
// If set, the last page is not flushed
}TFlushPageFlags;
The function writes the pages in memory to the PDF file. The function can be called every time a new
page was created or whenever the pages in memory are no longer required.
Calling the function on a memory based PDF file is not meaningful. The output file must already be
open before the function can be called. If no output file was set in CreateNewPDF() then open the
output file with OpenOutputFile() or OpenOutputFileEncrypted() beforehand. The latter one can be
used to create an encrypted PDF file.
Flushed pages can no longer be accessed with EditPage() but it is of course possible to add further
pages to the file.
 

Previous topic: FlattenForm

Next topic: FreeImageObjEx