Click or drag to resize

PdfDocument Class

Represent pdf document classes.
Inheritance Hierarchy
System Object
Spire.Pdf PdfDocument

Namespace: Spire.Pdf
Assembly: Spire.Pdf (in Spire.Pdf.dll) Version: 11.3.7.0 (11.3.7.1046)
Syntax
public class PdfDocument : IDisposable, 
	ICloneable

The PdfDocument type exposes the following members.

Constructors
Properties
Name Description
Public property AfterOpenAction
Gets or sets the action to execute when the document is opened.
Public property AfterPrintAction
Gets or sets the action to be performed after the document is printed.
Public property AfterSaveAction
Gets or sets the jave script action to be performed after the document is saved.
Public property Static member AIHelper
helper for call AI.
Public property AllowCreateForm
Get or Set Allow Create Form.
Public property Attachments
Gets the collection of document attachments displayed on a PDF page.
Public property BeforeCloseAction
Gets or sets the action to be performed before the document is closed.
Public property BeforePrintAction
Gets or sets the action to be performed before the document is printed.
Public property BeforeSaveAction
Gets or sets the java script action to be performed before the document is saved.
Public property Bookmarks
Gets the bookmarks.
Public property Collection
The pdf collections.
Public property ColorSpace
Gets or sets the color space for page that will be created.
Public property CompressionLevel
Gets or sets the desired level of stream compression.
Public property Conformance
Get document PdfConformanceLevel
Public property ConvertOptions
Set some options when do convert operation.
Public property DocumentInformation
Gets document's information and properties.
Public property DocumentPieceInfo
Gets or set the document piece info.
Public property Static member EnableFontCache
Indicates whether enable font cache.
Public property FileInfo
Gets or sets the pdf file info.
Public property Form
Gets the loaded form.
Public property IsEncrypted
Indicates the document is encrypted or not.
Public property IsPortfolio
Indicates the document is a PDF Portfolio or not.
Public property JavaScripts
Gets the additional document's actions.
Public property Layers
Optional content properties
Public property Metadata
Get or set the document metadata.
Public property PageLabels
Page labels.
Public property Pages
Gets the pages.
Public property PageSettings
Gets or sets the page setting.
Public property PDFStandard Obsolete.
Set,Get Current active pdf object
Public property PrintSettings
Get the print settings.
Public property Sections
Gets the section collections of pdf.
Public property Security Obsolete.
Gets the security parameters of the document.
Public property SecurityPolicy
Gets the document's security policy.
Public property Tag
The tag of object.
Public property Template
Gets the template of pdf document
Public property UsedFonts
Gets the fonts which are available in the PDF document.
Public property UseHighQualityImage Obsolete.
Indicates whether to use the high qulity image when convert document
Public property UseInvariantCulture Obsolete.
Indicates whether use invariant culture mode to convert pdf document.
Public property UsePsDirectlyForConvert Obsolete.
Public property ViewerPreferences
Gets or sets a viewer preferences object controlling the way the document is to be presented on the screen or in print.
Top
Methods
Name Description
Public method AppendPage
Appends a new page to this one.
Public method AppendPage(PdfDocument)
Appends the specified loaded document to this one.
Public method Static member ClearCustomFonts
Clear custom fonts.
Public method Static member ClearCustomFontsFolders Obsolete.
Clear the located custom font.
Public method Clone
Creates a new object that is a copy of the current instance.
Public method Close
Closes the document.
Public method CreateBooklet(String, Single, Single, Boolean)
Thie method creates a booklet
Public method CreateBooklet(String, Single, Single, Boolean, DrawPageInBookletEventHandler, DrawPageInBookletEventHandler)
Thie method creates a booklet
Public method Decrypt
Decrypts the document.
Public method Decrypt(String)
Decrypts the document.
Public method Dispose
Releases unmanaged resources and performs other cleanup operations before the is reclaimed by garbage collection.
Protected method Dispose(Boolean)
Releases all resources used.
Public method Encrypt
Encrypts the document.
Public method Equals
Determines whether the specified object is equal to the current object.
(Inherited from Object .)
Protected method Finalize (Overrides Object Finalize .)
Public method GetHashCode
Serves as the default hash function.
(Inherited from Object .)
Public method GetSignatureContent
Get pdf document regarding signature.
Public method GetType
Gets the Type of the current instance.
(Inherited from Object .)
Public method HasExtendedRight
Indicates whether contains extended right.
Public method InsertPage(PdfDocument, PdfPageBase)
Imports a page.
Public method InsertPage(PdfDocument, Int32)
Imports a page.
Public method InsertPage(PdfDocument, Int32, Int32)
Imports a page.
Public method InsertPageRange
Imports a page range from a loaded document.
Public method Static member IsPasswordProtected
Whether the file is password protected.
Public method Static member LoadCustomFontFolder
Load custom font folder.
Public method Static member LoadCustomFonts
Load custom fonts.
Public method LoadFromBytes( Byte )
Initializes a new instance of the class.
Public method LoadFromBytes( Byte , String)
Initializes a new instance of the class.
Public method LoadFromFile(String)
Initializes a new instance of the class.
Public method LoadFromFile(String, FileFormat)
Initializes a new instance of the class.
Public method LoadFromFile(String, String)
Initializes a new instance of the class.
Public method LoadFromHTML(String, Boolean, PdfPageSettings, PdfHtmlLayoutFormat) Obsolete.
Load htmlSourceCode to Pdf
Public method LoadFromHTML(String, Boolean, Boolean, Boolean) Obsolete.
Load file from disk file.
Public method LoadFromHTML(String, Boolean, PdfPageSettings, PdfHtmlLayoutFormat, Boolean) Obsolete.
Load htmlSourceCode to Pdf
Public method LoadFromHTML(String, Boolean, Boolean, Boolean, PdfPageSettings) Obsolete.
Load file from disk file.
Public method LoadFromHTML(String, Boolean, Boolean, Boolean, PdfPageSettings, PdfHtmlLayoutFormat) Obsolete.
Load file from disk file.
Public method LoadFromHTML(String, Boolean, Boolean, Boolean, PdfPageSettings, PdfHtmlLayoutFormat, Boolean) Obsolete.
Load file from disk file.
Public method LoadFromStream(Stream)
Initializes a new instance of the class.
Public method LoadFromStream(Stream, String)
Initializes a new instance.
Public method LoadFromSvg(Stream)
Load a svg stream.
Public method LoadFromSvg(String)
Load a svg file.
Public method LoadFromXPS( Byte )
Load a xps bytes array.
Public method LoadFromXPS(Stream)
Load a xps stream.
Public method LoadFromXPS(String)
Load a xps file.
Protected method MemberwiseClone
Creates a shallow copy of the current Object .
(Inherited from Object .)
Public method Static member Merge
Merges the specified source documents and return destination document. ***It is recommended to use method "MergeFiles(string[] inputFiles, string outputFile)" or "MergeFiles(stream[] inputFiles, stream[] outputFile)", which automatically release srcFiles and mergeFils resources after merging.***
Public method Static member MergeFiles( Stream )
Merges the PDF documents specified by the Stream. ***It is recommended to use method "MergeFiles(string[] inputFiles, string outputFile)" or "MergeFiles(stream[] inputFiles, stream[] outputFile)", which automatically release srcFiles and mergeFils resources after merging.***
Public method Static member MergeFiles( String )
Merges the PDF documents specified by the paths. ***It is recommended to use method "MergeFiles(string[] inputFiles, string outputFile)" or "MergeFiles(stream[] inputFiles, stream[] outputFile)", which automatically release srcFiles and mergeFils resources after merging.***
Public method Static member MergeFiles( Stream , Stream)
Merge the PDF documents.
Public method Static member MergeFiles(String, String) Obsolete.
Merges the PDF documents specified by the paths.
Public method Static member MergeFiles( String , String)
Merge the PDF documents.
Public method Preview
Print preview.
Public method Print
Print document.
Public method Print(PdfPrintSettings)
Print document.
Public method RegisterProgressNotifier
Register progress notifier. Only SaveToFile() and SaveToStream() methods are supported to obtain the progress.
Public method RemoveDocumentJavaScript
remove document's javaScript
Public method RemoveExtendedRight
Removes the extended right.
Public method SaveAsImage(Int32)
Saves PDF document page as image
Public method SaveAsImage(Int32, PdfImageType)
Saves PDF document page as image
Public method SaveAsImage(Int32, Int32, Int32)
Saves PDF document page as image,Set image Dpi
Public method SaveAsImage(Int32, PdfImageType, Int32, Int32)
Saves PDF document page as image,Set PdfImageType and image Dpi.
Public method SaveToFile(String)
Saves PDF document to file.
Public method SaveToFile(String, FileFormat)
Saves PDF document to file.
Public method SaveToFile(String, Int32, Int32, FileFormat)
Saves PDF document to PDF or other Format files. Current only supports save PDF document to SVG and PDF
Public method SaveToStream(Stream)
Save the document to the specified stream.
Public method SaveToStream(FileFormat)
Convert the document to streams with the file format.
Public method SaveToStream(Stream, FileFormat)
Convert the document to an stream with the file format.
Public method SaveToStream(Int32, Int32, FileFormat)
Convert the document to streams with the file format.
Public method Static member SetCustomFontsFolders Obsolete.
Set the path to the folder where the custom font is located.
Public method Split(String)
Splits a PDF file to many PDF files, each of them consists of one page from the source file.
Public method Split(String, Int32)
Splits a PDF file to many PDF files, each of them consists of one page from the source file.
Public method SprnpsPgH0nUR8K0SSNXCtXNHDX7
»ñÈ¡ÄÚ²¿·ÃÎÊʵÀý.
Public method Sprq6dQUdRyjFEAEAuLARDhJ
ÉèÖÃÄÚ²¿LicensewÐÅÏ¢(doc viewer, office viewer).
Public method ToString
Returns a string that represents the current object.
(Inherited from Object .)
Public method VerifySignature
Verify pdf document regarding signature.
Top
See Also