Sdílet prostřednictvím


SPSiteSubscriptionSettingsManager.AssignFeaturePackToSiteSubscription method

Assigns the specified feature definition set to the specified site subscription object.

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

Syntax

'Declaration
Public Sub AssignFeaturePackToSiteSubscription ( _
    featurePack As SPSiteSubscriptionFeaturePack, _
    siteSubscription As SPSiteSubscription _
)
'Usage
Dim instance As SPSiteSubscriptionSettingsManager
Dim featurePack As SPSiteSubscriptionFeaturePack
Dim siteSubscription As SPSiteSubscription

instance.AssignFeaturePackToSiteSubscription(featurePack, _
    siteSubscription)
public void AssignFeaturePackToSiteSubscription(
    SPSiteSubscriptionFeaturePack featurePack,
    SPSiteSubscription siteSubscription
)

Parameters

  • featurePack
    Type: Microsoft.SharePoint.SPSiteSubscriptionFeaturePack

    The site subscription feature definition set to assign. If a previous assignment exists, it is overwritten. Passing in a null value for featurePack removes a pre-existing assignment.

Exceptions

Exception Condition
ArgumentNullException

The specified site subscription does not exist.

SecurityException

The current user is not a farm administrator.

See also

Reference

SPSiteSubscriptionSettingsManager class

SPSiteSubscriptionSettingsManager members

Microsoft.SharePoint namespace