MainDocumentPart.AddImagePart Method (ImagePartType)

Adds a ImagePart to the MainDocumentPart.

Namespace:  DocumentFormat.OpenXml.Packaging
Assembly:  DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)

Syntax

'Declaration
Public Function AddImagePart ( _
    partType As ImagePartType _
) As ImagePart
'Usage
Dim instance As MainDocumentPart
Dim partType As ImagePartType
Dim returnValue As ImagePart

returnValue = instance.AddImagePart(partType)
public ImagePart AddImagePart(
    ImagePartType partType
)

Parameters

Return Value

Type: DocumentFormat.OpenXml.Packaging.ImagePart
The newly added part.

See Also

Reference

MainDocumentPart Class

MainDocumentPart Members

AddImagePart Overload

DocumentFormat.OpenXml.Packaging Namespace