I might have stumbled over a huge "gotcha" in SharePoint Online. Currently on the E3 plan.

I have created a site collection from the "Blank Site" template (not wanting a cluttered workspace), and have added about 20 custom content types manually. As it turns out, I would now like to add Managed Metadata columns to some of these content types. I try to add a column, but the Term picker shows the message

"The required feature is not enabled for this column type"

It turns out that this message is displayed because the hidden feature TaxonomyFieldAdded is not activated for site collections created from the Blank Site template. On a standalone SharePoint installation, you would just run "Enable-SPFeature -Id TaxonomyFieldAdded -url (SiteUrl)" in PowerShell. But neither PowerShell nor STSADM are available in SharePoint Online, and the required feature is not accessible from the Site Settings interface.

So on the off chance that I am wrong about this, does anyone know a way to enable this feature in SharePoint online? Or do I end up having to delete this site collection and re-build all my content types manually?

有帮助吗?

解决方案

I would build a sandboxed web template and use the technique where your web feature activates the required site features. So this web feature will have properties whose values are site feature GUIDs you want to activate.

For example, in your onet.xml under WebFeatures section, you can:

<Feature ID="your web scoped feature GUID">

    <Properties xmlns="http://schemas.microsoft.com/sharepoint">
         <Property Key="TaxonomyFieldAddedActivatorFeature" Value="taxonomyfieldadded feature guid" />
    </Properties>

</Feature>

Here is my blog post which shows how I have used in my web template. The only difference is the blog post talks about the web template deployed as a farm feature.

If you don't want to build a web template, just create a sandboxed feature and activate that feature in that site. In that case, you can directly create a site scoped feature.

Hope that helps.

其他提示

Funny story: I contacted Microsoft Support about a problem which manifested with the same symptoms after upgrading to SharePoint Online from BPOS. The Microsoft rep sent me a WSP file which can be activated in a sandboxed solution of an existing site to activate this feature. It does the same thing Chakkaradeep Chandran suggested, but for an existing site instead of a new one. The WSP (CAB) file contains two files:

Feature.xml:

<Feature Title="Enable Hidden Features"
     Id="{A8457EAD-8541-41c4-AA69-2C4059569748}"
     Scope="Site"
     Description="Enables Managed Metadata and other hidden features for blank sites"
     Version="14.0.0.0" 
     Hidden="FALSE"
     DefaultResourceFile="core" 
     xmlns="http://schemas.microsoft.com/sharepoint/">
<ActivationDependencies>
    <ActivationDependency FeatureId="73ef14b1-13a9-416b-a9b5-ececa2b0604c" />
</ActivationDependencies>

manifest.xml:

<Solution SolutionId="{7DB2A941-C02F-42f1-905F-5B892E3C64AA}" xmlns="http://schemas.microsoft.com/sharepoint/"> 
    <FeatureManifests>
        <FeatureManifest Location="ActivateHidden\Feature.xml" />
    </FeatureManifests>
</Solution>

Just package these in a WSP (CAB) file, and assuming that none of the GUIDs in there are unique to my environment, you should be good to go. Upload as sandboxed, activate feature at the site collection level. Funny how contacting support can occasionaly save hours of local troubleshooting.

creating the wsp from "funny story" works. The feature.xml is missing the closing tag and the feature.xml should be in the folder ActivateHidden.

To create WSP I use IZArc. Select the manifest file and folder and zip it. Select the zip and use IZArc to convert to archive. Select .cab as output. And finally rename the cab file to wsp.

许可以下: CC-BY-SA归因
scroll top