Share via


SPContentDatabase.QueryFeatures method (SPFeatureScope, Boolean)

Gets all site- or Web-scoped features that need to be upgraded, or all that do not, as specified.

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

Syntax

'Declaration
Public Function QueryFeatures ( _
    scope As SPFeatureScope, _
    needsUpgrade As Boolean _
) As SPFeatureQueryResultCollection
'Usage
Dim instance As SPContentDatabase
Dim scope As SPFeatureScope
Dim needsUpgrade As Boolean
Dim returnValue As SPFeatureQueryResultCollection

returnValue = instance.QueryFeatures(scope, _
    needsUpgrade)
public SPFeatureQueryResultCollection QueryFeatures(
    SPFeatureScope scope,
    bool needsUpgrade
)

Parameters

  • needsUpgrade
    Type: System.Boolean

    true to include only the features that need to be upgraded; false to include only those that do not need to be upgraded.

Return value

Type: Microsoft.SharePoint.SPFeatureQueryResultCollection
The site- or Web-scoped features as filtered by needsUpgrade.

Remarks

scope must be site or Web.

See also

Reference

SPContentDatabase class

SPContentDatabase members

QueryFeatures overload

Microsoft.SharePoint.Administration namespace