Share via


IPackage.CreatePart(Uri, String, CompressionOption) Method

Definition

Creates a new part with a given URI, content type, and compression option.

public DocumentFormat.OpenXml.Packaging.IPackagePart CreatePart (Uri partUri, string contentType, System.IO.Packaging.CompressionOption compressionOption);
abstract member CreatePart : Uri * string * System.IO.Packaging.CompressionOption -> DocumentFormat.OpenXml.Packaging.IPackagePart
Public Function CreatePart (partUri As Uri, contentType As String, compressionOption As CompressionOption) As IPackagePart

Parameters

partUri
Uri

The URI of the new part.

contentType
String

The content type of the data stream.

compressionOption
CompressionOption

The compression option for the data stream.

Returns

The new created part.

Applies to