Information
The topic you requested is included in another documentation set. For convenience, it's displayed below. Choose Switch to see the topic in its original location.

Package.CreatePart Method

Creates a new package part.

Name Description
Package.CreatePart (Uri, String) Creates a new uncompressed part with a specified URI and content type.
Package.CreatePart (Uri, String, CompressionOption) Creates a new part with a specified URI, content type, and compression option.

CreatePart instantiates an empty Stream for the new part. The GetStream method can be used to obtain a reference to the stream instance associated with the part.

For more information about package parts see section 1.1 of the Open Packaging Conventions (OPC) specification available for download at http://go.microsoft.com/fwlink/?LinkID=71255.

Notes to Implementers: CreatePart internally calls the derived class CreatePartCore method to actually create the part based on the physical format implemented in the derived class.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

Show:
© 2014 Microsoft