Today i was trying to activate site collection feature through Powershell and it was harder then i expected. There are a lot of blog posts out there which shows how to activate a feature through Powershell by providing the name of the feature. Here is the command to activate the feature if you know the name of the feature:
“Enable-SPFeature -Identity $featureName -Url $sitecollection.Url”
But what if you dont know the name of the feature? Features names that you see in SharePoint GUI are not the same that Powershell use. Specially if you have site collection in language other then English.
Lets say i want to activate feature following feature:
So here are the steps to find out feature name.
- Go to site collection features.
- Find the feature you want to activate in GUI and activate it.
- Go back to the feature you activated before and click on deactivate feature.
- Note the feature GUID in the Url.
- Do not deactivate the feature.
- Run the following command in powershell.
Here you can find display name of feature.
Hope this will save you sometime.