PackagingProgressEventArgs Constructor (PackagingAction, Int32)

 

Initializes a new instance of the PackagingProgressEventArgs class.

Namespace:   System.Windows.Xps.Packaging
Assembly:  ReachFramework (in ReachFramework.dll)

public:
PackagingProgressEventArgs(
	PackagingAction action,
	int numberCompleted
)

Parameters

action
Type: System.Windows.Xps.Packaging::PackagingAction

The action that the packaging process is currently performing.

numberCompleted
Type: System::Int32

The number of simultaneous times that the specified action occurred.

In certain situations and for specific types, multiple packaging progress events occur at the same time. These logically distinct, but temporally identical, events are combined into a single PackagingProgressEvent and numberCompleted is more than 1. For example, when you print, font subsetting is performed every four pages. Each page must be cached until the subsetting is complete, and then all four FixedPageCompleted events occur at the same time. The constructor for the resulting PackagingProgressEventArgs sets action to FixedPageCompleted and sets numberCompleted to 4.

For example, if a package consists of a single four-page document that uses one font and no images or other resources, the sequence of events might occur as shown in the following table.

The sequence of events for a simple package

AddingDocumentSequence

1

AddingFixedDocument

1

AddingFixedPage

1

AddingFixedPage

1

AddingFixedPage

1

AddingFixedPage

1

FontAdded

1

FixedPageCompleted

4

FixedDocumentCompleted

1

DocumentSequenceCompleted

1

XpsDocumentCommitted

1

.NET Framework
Available since 3.0
Return to top
Show: