PDF Creator Pilot documentation |
Download CHM version of this manual. |
|
![]() ![]() Collapse AllGets and sets value indicating should the library create a PDF document in memory, instead of a file on the disk.
|
| VARIANT_BOOL GenerateInMemoryFile { get; set; } |
Value
VARIANT_TRUE if document is generated in memory without saving on disk. VARIANT_FALSE otherwise.
Remarks
If the GenerateInMemoryFile property equals TRUE, the library generates an in-memory file that can be read through the OutputByteStream property. Use the BinaryImage property for stream writing PDF, such as writing directly to the browser. To get the size of the file created in memory, you can use the MemoryFileSize property. To use this property in the full version of the library, you must have an additional Web License.
Example
Generate PDF file in memory
Delphi
[copy to clipboard]
{ PDF object is supposed to be created }
PDF.StartEngine('demo', 'demo');
PDF.GenerateInMemoryFile := true;
PDF.BeginDoc;
{ some operations here... }
PDF.EndDoc;
{ Now we have PDF file in memory. }
{ Use PDF.BinaryImage or PDF.OutputByteStream to access it. }
C/C++
[copy to clipboard]
// PDF object is supposed to be created
PDF->StartEngine("demo", "demo");
PDF->GenerateInMemoryFile = TRUE;
PDF->BeginDoc();
// some operations here...
PDF->EndDoc();
// Now we have PDF file in memory.
// Use PDF.BinaryImage or PDF.OutputByteStream to access it.
C#
[copy to clipboard]
// PDF object is supposed to be created
PDF.StartEngine("demo", "demo");
PDF.GenerateInMemoryFile = true;
PDF.BeginDoc();
// some operations here...
PDF.EndDoc();
// Now we have PDF file in memory.
// Use PDF.BinaryImage or PDF.OutputByteStream to access it.
Visual Basic
[copy to clipboard]
' PDF object is supposed to be created
PDF.StartEngine("demo", "demo")
PDF.GenerateInMemoryFile = True
PDF.BeginDoc
' some operations here...
PDF.EndDoc
' Now we have PDF file in memory.
' Use PDF.BinaryImage or PDF.OutputByteStream to access it.
See Also


