SPFeatureCollection.Add method (Guid, Int32, Boolean, SPFeatureDefinitionScope)
Adds a Feature to the Collection.
Namespace: Microsoft.SharePoint
Assembly: Microsoft.SharePoint (in Microsoft.SharePoint.dll)
Syntax
'Declaration
Public Function Add ( _
featureId As Guid, _
compatibilityLevel As Integer, _
force As Boolean, _
featdefScope As SPFeatureDefinitionScope _
) As SPFeature
'Usage
Dim instance As SPFeatureCollection
Dim featureId As Guid
Dim compatibilityLevel As Integer
Dim force As Boolean
Dim featdefScope As SPFeatureDefinitionScope
Dim returnValue As SPFeature
returnValue = instance.Add(featureId, _
compatibilityLevel, force, featdefScope)
public SPFeature Add(
Guid featureId,
int compatibilityLevel,
bool force,
SPFeatureDefinitionScope featdefScope
)
Parameters
featureId
Type: System.GuidFeature ID
compatibilityLevel
Type: System.Int32Feature's Compatibility Level
force
Type: System.BooleanForce this feature to be activated
featdefScope
Type: Microsoft.SharePoint.SPFeatureDefinitionScopeSPFeatureDefinitionScope
Return value
Type: Microsoft.SharePoint.SPFeature