Platforms to show: All Mac Windows Linux Cross-Platform

Back to PDFDocumentMBS class.

PDFDocumentMBS.allowsCommenting as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 21.1 ✅ Yes ❌ No ❌ No ✅ Yes All
A Boolean value indicating whether you can create or modify document annotations, including form field entries.

Available in macOS 10.13 or newer.
(Read only property)

PDFDocumentMBS.allowsContentAccessibility as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 21.1 ✅ Yes ❌ No ❌ No ✅ Yes All
A Boolean value indicating whether you can extract content from the document, but only for the purpose of accessibility.

Available in macOS 10.13 or newer.
(Read only property)

PDFDocumentMBS.allowsCopying as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Whether copying is allowed.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(doc.allowsCopying)

Even unlocked, encrypted PDF's may have certain restrictions regarding copying or printing placed upon them.
(Read only property)

PDFDocumentMBS.allowsDocumentAssembly as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 21.1 ✅ Yes ❌ No ❌ No ✅ Yes All
A Boolean value indicating whether you can manage a document by inserting, deleting, and rotating pages.

Available in macOS 10.13 or newer.
(Read only property)

PDFDocumentMBS.allowsDocumentChanges as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 21.1 ✅ Yes ❌ No ❌ No ✅ Yes All
A Boolean value indicating whether you can modify the document contents except for document attributes.

Available in macOS 10.13 or newer.
(Read only property)

PDFDocumentMBS.allowsFormFieldEntry as Boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 21.1 ✅ Yes ❌ No ❌ No ✅ Yes All
A Boolean value indicating whether you can modify form field entries even if you can't edit document annotations.

Available in macOS 10.13 or newer.
(Read only property)

PDFDocumentMBS.allowsPrinting as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Whether printing is allowed.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(doc.allowsPrinting)

Even unlocked, encrypted PDF's may have certain restrictions regarding copying or printing placed upon them.
(Read only property)

PDFDocumentMBS.Author as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
String containing document author.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.Author

(Read and Write property)

PDFDocumentMBS.CreationDate as Date

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Date representing document creation date.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.CreationDate.LongDate

(Read and Write property)

PDFDocumentMBS.CreationDateTime as DateTime

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 20.5 ✅ Yes ❌ No ❌ No ✅ Yes All
Date representing document creation date.

(Read and Write property)

PDFDocumentMBS.Creator as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
String containing name of app that created document content.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.Creator

(Read and Write property)

PDFDocumentMBS.documentRef as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 11.2 ✅ Yes ❌ No ❌ No ✅ Yes All
Returns a CGPDFDocumentRef value for this document.

This is the CGPDFDocument associated with the PDFDocument object. With this object you can call many CoreGraphics API. May return 0 if the document was not created from an existing PDF file or data.

Use CGPDFDocumentMBS with Constructor taking a handle to call functions on this CGPDFDocument object.
(Read only property)

PDFDocumentMBS.documentURL as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
The document location.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.documentURL

May return nil if the document was created from data.
(Read only property)

PDFDocumentMBS.Handle as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 10.4 ✅ Yes ❌ No ❌ No ✅ Yes All
The internal reference to the PDF Document.

(Read and Write property)

PDFDocumentMBS.isEncrypted as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Whether the PDF is encrypted.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(doc.isEncrypted)

With the right password, a PDF can be unlocked - nontheless, the PDF still indicates that it is encrypted - just no longer locked. Some PDF's may be encrypted but can be unlocked with the empty string.
These are unlocked automatically.
(Read only property)

PDFDocumentMBS.isFinding as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Returns true if document is currently searching for a string.

(Read only property)

PDFDocumentMBS.isLocked as boolean

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Whether the PDF is locked.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(doc.isLocked)

With the right password, a PDF can be unlocked - nontheless, the PDF still indicates that it is encrypted - just no longer locked. Some PDF's may be encrypted but can be unlocked with the empty string.
These are unlocked automatically.
(Read only property)

PDFDocumentMBS.majorVersion as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
PDF version of the PDF file (example: major version = 1, minor = 4; PDF v1.4).
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(doc.majorVersion)+"."+str(Doc.minorVersion)

(Read only property)

PDFDocumentMBS.minorVersion as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
PDF version of the PDF file (example: major version = 1, minor = 4; PDF v1.4).
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(doc.majorVersion)+"."+str(Doc.minorVersion)

(Read only property)

PDFDocumentMBS.ModificationDate as Date

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ❌ No Desktop, Console & Web
Date representing last document modification date.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.ModificationDate.LongDate

(Read and Write property)

PDFDocumentMBS.ModificationDateTime as DateTime

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 20.5 ✅ Yes ❌ No ❌ No ✅ Yes All
Date representing last document modification date.

(Read and Write property)

PDFDocumentMBS.outlineRoot as PDFOutlineMBS

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
Returns the root outline object for the PDF (or nil if none).

(Read and Write property)

Some examples using this property:

PDFDocumentMBS.pageCount as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
The number of pages in the document.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox str(Doc.pageCount)

(Read only property)

PDFDocumentMBS.permissionsStatus as Integer

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 9.6 ✅ Yes ❌ No ❌ No ✅ Yes All
Returns the permissions status of the PDF document.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)

Select case doc.permissionsStatus
case doc.kPDFDocumentPermissionsNone
MsgBox "None"
case doc.kPDFDocumentPermissionsOwner
MsgBox "Owner or no password"
case doc.kPDFDocumentPermissionsUser
MsgBox "User"
end Select

You have kPDFDocumentPermissionsNone status for an encrypted document that you have not supplied either a valid user or owner password. For a document with no encryption, you automatically have kPDFDocumentPermissionsOwner status.

Requires Mac OS X 10.6.
(Read only property)

PDFDocumentMBS.Producer as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
String containing name of app that produced PDF data.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.Producer

(Read and Write property)

PDFDocumentMBS.stringValue as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
The text of the document.
Example
dim p as PDFDocumentMBS
dim f as FolderItem

f=SpecialFolder.Desktop.Child("test.pdf")
p=new PDFDocumentMBS(f)

MsgBox "Text from PDF Document:"+EndOfLine+EndOfLine+p.stringValue

Convenience method. Returns a string representing the entire document (each page's string concatenated with line feeds between pages).

If you need to extract the text of a PDF document cross platform or with more options, you may want to look on the DynaPDF plugin.

It seems like this string value is not always available. It works for PDF Documents created from a disc file, but not for files our test app created on runtime in memory by using PDFDocument constructor and insertpage.
(Read only property)

PDFDocumentMBS.Subject as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
String containing document subject.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.Subject

(Read and Write property)

PDFDocumentMBS.Title as string

Type Topic Plugin Version macOS Windows Linux iOS Targets
property PDFKit MBS PDFKit Plugin 8.0 ✅ Yes ❌ No ❌ No ✅ Yes All
String containing document title.
Example
dim f as FolderItem = SpecialFolder.Desktop.Child("test.pdf")
dim doc as new PDFDocumentMBS(f)
MsgBox doc.Title

(Read and Write property)

The items on this page are in the following plugins: MBS PDFKit Plugin.


The biggest plugin in space...