Compartilhar via


ContentTypePublisher.Unpublish Method

Unpublishes a content type on the specified hub site.

Namespace:  Microsoft.SharePoint.Taxonomy.ContentTypeSync
Assembly:  Microsoft.SharePoint.Taxonomy (in Microsoft.SharePoint.Taxonomy.dll)

Syntax

'Declaration
Public Sub Unpublish ( _
    contentType As SPContentType _
)
'Usage
Dim instance As ContentTypePublisher
Dim contentType As SPContentType

instance.Unpublish(contentType)
public void Unpublish(
    SPContentType contentType
)

Parameters

Exceptions

Exception Condition
UnauthorizedAccessException

The user must have rights to add or customize pages to be able to perform this operation.

ContentTypeSyndicationException

The content type fails to be unpublished on one or more associated service applications.

Remarks

If there are multiple service applications associated with the current hub site and one or more are using the current site as the hub, the content type is unpublished for all of those associated service applications.

See Also

Reference

ContentTypePublisher Class

ContentTypePublisher Members

Microsoft.SharePoint.Taxonomy.ContentTypeSync Namespace