Share via


SPMimeMappingCollection.Add method

Adds a new MIME mapping entry to the collection of MIME mapping entries. Note that Update on the parent object must called to commit this change to the underlying store.

Namespace:  Microsoft.SharePoint.Administration
Assembly:  Microsoft.SharePoint (in Microsoft.SharePoint.dll)

Syntax

'Declaration
Public Sub Add ( _
    extension As String, _
    progId As String, _
    mimeType As String _
)
'Usage
Dim instance As SPMimeMappingCollection
Dim extension As String
Dim progId As String
Dim mimeType As String

instance.Add(extension, progId, mimeType)
public void Add(
    string extension,
    string progId,
    string mimeType
)

Parameters

  • extension
    Type: System.String

    Extension of the files to be MIME mapped. Extension must not start with a period .. Note that extensions are considered in a case insensitive manner.

  • progId
    Type: System.String

    ProgId of the files to be MIME mapped.

  • mimeType
    Type: System.String

    Target MIME type to return with matching files.

See also

Reference

SPMimeMappingCollection class

SPMimeMappingCollection members

Microsoft.SharePoint.Administration namespace