Components | All | New | MacOS | Windows | Linux | iOS | ||||
Examples | Mac & Win | Server | Client | Guides | Statistic | FMM | Blog | Deprecated | Old |
DynaPDF.HaveOpenDocument
Whether we have a working document.
Component | Version | macOS | Windows | Linux | Server | iOS SDK |
DynaPDF | 7.1 | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes | ✅ Yes |
MBS( "DynaPDF.HaveOpenDocument"; PDF ) More
Parameters
Parameter | Description | Example |
---|---|---|
The PDF reference returned from DynaPDF.New. |
Result
Returns 1, 0 or error.
Description
Whether we have a working document.If an error occurred it is not always clear whether the PDF file was already deleted or if it is still in memory. Therefore, this function can be used to determine whether a PDF file is still in memory.
If an open PDF file is in memory the return value is 1. If no open PDF file is in memory the return value is 0.
See also HaveOpenDocument function in DynaPDF manual.
Examples
Save PDF only if we have a document and there was no error:
If [ MBS("DynaPDF.HaveOpenDocument"; $pdf) ]
Set Variable [ $PDFData ; Value: MBS("DynaPDF.Save"; $pdf; "hello.pdf") ]
Set Field [ Create Text::PDF ; $PDFData ]
End If
See also
Release notes
- Version 7.1
- Added DynaPDF.HaveOpenDocument and DynaPDF.HaveOpenPage.
Blog Entries
This function checks for a license.
Created 12nd February 2017, last changed 3th January 2021
