MainDocumentPart.AddAlternativeFormatImportPart Method (String)

Adds a AlternativeFormatImportPart to the MainDocumentPart.

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

Syntax

'Declaration
Public Function AddAlternativeFormatImportPart ( _
    contentType As String _
) As AlternativeFormatImportPart
'Usage
Dim instance As MainDocumentPart
Dim contentType As String
Dim returnValue As AlternativeFormatImportPart

returnValue = instance.AddAlternativeFormatImportPart(contentType)
public AlternativeFormatImportPart AddAlternativeFormatImportPart(
    string contentType
)

Parameters

  • contentType
    Type: System.String
    the content type of the AlternativeFormatImportPart

Return Value

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

See Also

Reference

MainDocumentPart Class

MainDocumentPart Members

AddAlternativeFormatImportPart Overload

DocumentFormat.OpenXml.Packaging Namespace