New to Telerik Document ProcessingStart a free 30-day trial

Root fixed document aggregating pages, annotations, form fields, actions, bookmarks, structure tree, and metadata, with merge and clone operations.

Definition

Namespace:Telerik.Windows.Documents.Fixed.Model

Assembly:Telerik.Windows.Documents.Fixed.dll

Syntax:

C#
public class RadFixedDocument : FixedDocumentElementBase, IFixedDocument, IDestinationContainer, IFixedDocumentElement

Inheritance: objectFixedDocumentElementBaseRadFixedDocument

Implements: IDestinationContainerIFixedDocumentIFixedDocumentElement

Inherited Members FixedDocumentElementBase.Parent

Constructors

Create an empty document with initialized collections and optional automatic tagging.

C#
public RadFixedDocument(bool autoTag = false)
Parameters:autoTagbool

Events

Occurs when an unhandled exception is thrown while loading the document properties, e.g. page content and annotations. This event applies when the document is imported with the PdfFormatProvider class using the ReadingMode.OnDemand import setting.

C#
public event EventHandler<DocumentUnhandledExceptionEventArgs> DocumentUnhandledException

Raised to resolve duplicate embedded file names during merge.

C#
public event EventHandler<DuplicatedEmbeddedFileNameResolvingEventArgs> MergedEmbeddedFileNameResolving

Raised to resolve duplicate form field names during merge; handler can supply a unique name.

C#
public event EventHandler<MergedFormFieldNameResolvingEventArgs> MergedFieldNameResolving

Raised to resolve duplicate JavaScript action names during merge.

C#
public event EventHandler<DuplicatedJavaScriptNameResolvingEventArgs> MergedJavaScriptNameResolving

Methods

Deep clone the document (pages, form fields, annotations, destinations, files, scripts, bookmarks) into a new instance.

C#
public RadFixedDocument Clone()
Returns:

RadFixedDocument

The cloned RadFixedDocument instance.

Creates a new RadFixedDocument containing deep copies of the pages in the specified range. Form fields with widgets on included pages, named destinations pointing to included pages, embedded files, JavaScript actions, and bookmarks are also cloned into the new document.

C#
public RadFixedDocument Clone(int startPageIndex, int pageCount)
Parameters:startPageIndexint

The zero-based index of the first page to include.

pageCountint

The number of consecutive pages to include.

Returns:

RadFixedDocument

A new RadFixedDocument containing the cloned page range.

Exceptions:

ArgumentOutOfRangeException

startPageIndex is negative, pageCount is less than 1, or the range exceeds the document page count.

Merge pages, form fields, destinations, actions, scripts, files, and bookmarks from another document.

C#
public void Merge(RadFixedDocument source)
Parameters:sourceRadFixedDocument

The source document.

Export a plain text representation of the entire document.

C#
[Obsolete("This method is obsolete. Please use ToSimpleTextDocument(TimeSpan? timeout) instead.")]
public SimpleTextDocument ToSimpleTextDocument()
Returns:

SimpleTextDocument

An instance of SimpleTextDocument representing the plain text version of the document.

Converts the current document to a plain text document.

C#
public SimpleTextDocument ToSimpleTextDocument(int startPage, int endPage, TimeSpan? timeout)
Parameters:startPageint

The starting page index (inclusive) from which to extract text.

endPageint

The ending page index (inclusive) up to which to extract text.

timeoutTimeSpan?

The timeout after which the operation will be cancelled.

Returns:

SimpleTextDocument

An instance of SimpleTextDocument representing the plain text version of the document.

Export a plain text representation limited to the specified page range.

C#
[Obsolete("This method is obsolete. Please use ToSimpleTextDocument(int startPage, int endPage, TimeSpan? timeout) instead.")]
public SimpleTextDocument ToSimpleTextDocument(int startPage, int endPage)
Parameters:startPageintendPageintReturns:

SimpleTextDocument

An instance of SimpleTextDocument representing the plain text version of the document.

Converts the current document to a plain text document.

C#
public SimpleTextDocument ToSimpleTextDocument(TimeSpan? timeout)
Parameters:timeoutTimeSpan?

The timeout after which the operation will be cancelled.

Returns:

SimpleTextDocument

An instance of SimpleTextDocument representing the plain text version of the document.

Properties

Interactive form (AcroForm) container managing form fields and widgets.

C#
public AcroForm AcroForm { get; }

Document-level actions executed on open, close, save, or print events.

C#
public DocumentActionCollection Actions { get; }

Enumerates all annotations across every page (lazy per page load).

C#
public IEnumerable<Annotation> Annotations { get; }
Property Value:

An enumerable collection of all annotations across all document pages.

Indicates whether new content is auto-tagged for accessibility.

C#
public bool AutoTag { get; }

Hierarchical outline (bookmarks) tree for structured navigation.

C#
public BookmarksCollection Bookmarks { get; }

Document metadata (info dictionary) including title, author, creation date, etc.

C#
public RadFixedDocumentInfo DocumentInfo { get; }
Property Value:

The document information object containing metadata properties.

Embedded file attachments collection.

C#
public EmbeddedFilesCollection EmbeddedFiles { get; }
Property Value:

The collection of embedded file attachments.

Indicates presence of optional content groups (layers).

C#
public bool HasLayers { get; }

BCP 47 language tag applied to document content.

C#
public string Language { get; set; }

Named destination targets enabling internal navigation by name.

C#
public NamedDestinationsCollection NamedDestinations { get; }
Property Value:

The collection of named destinations for document navigation.

Initial viewer page display mode (e.g., outline, thumbnails) when opened.

C#
public PageMode PageMode { get; set; }

Ordered page collection forming the document body.

C#
public PageCollection Pages { get; }
Property Value:

The collection containing all pages in the document.

Gets the PDF Portfolio/Collection settings for enhanced presentation of embedded files. Set IsEnabled to true to enable portfolio mode.

C#
public PortfolioCollection Portfolio { get; }
Remarks:

PDF Portfolios (also known as PDF Collections or PDF Packages) allow organizing multiple embedded files within a single PDF with a structured user interface showing file metadata in columns (details view) or icons (tile view). This feature was introduced in PDF 1.7.

Logical structure tree root describing tagged PDF semantics.

C#
public StructureTree StructureTree { get; set; }

Gets the viewer preferences controlling the way the document is to be presented on the screen or in print. If no such dictionary is specified, viewing and printing applications should behave in accordance with their own current user preference settings.

C#
public ViewerPreferences ViewerPreferences { get; }
Property Value:

The viewer preferences.