@provisionpoint ProvisionPoint
January 14, 2019
Serverless in Azure Government
January 14, 2019

Sharepoint 2010 content type deployment error in VS 2010

Hi Reddit Sharepoint community,

maybe you can help me with a problem I am struggling with while developing a state machine approval workflow for Sharepoint 2010 using Visual Studio 2010 (no Sharepoint Designer).

In my workflow I create one task per state, each one for a different user/group. Some tasks only require the assigned user to approve the process and optionally add a comment, moving the workflow to the next state, where a new task for another user is created; others need the user to add certain info to the underlying list element. After each step, the list element is updated with the added info from the task.

I created two projects in VS 2010. One only contains the workflow itself. The other one includes the list definition and list instance, as well as the content types for the list item and each task type, plus customized forms for each content type.

My problem is: Whenever I wanna deploy my content type project, I get the following error:

Error occurred in deployment step ‘Activate features’: The content type with Id ‘0x0100[my content type guid]’ defined in feature ‘[my feature guid]’ was found in the current site collection or in a subsite.

The only way to redeploy it seems to be following these steps:

  1. Delete the whole website, including its lists and list elements.
  2. Delete it from the recycle bin of the website collection.
  3. Delete the feature containing the content types using the Sharepoint Management Shell (Uninstall-SPFeature).
  4. Create a new website and a task list within it.
  5. Redeploy the content type project.

After that I need to update the list references in the workflow project, and it works again.

All of this is extremely time consuming, and up to a certain point (I don’t know when exactly), I could just redeploy my content type project, and it would simply overwrite any existing content types. If I knew when that changed, I might be able to find the solution myself, but I’m afraid I didn’t notice right away.

In VS 2010, I selected “Web” as the scope for my project, so I’m confused why it wouldn’t uninstall the feature along with deleting the website.

Does anyone have an idea what I could do?

Thanks

submitted by /u/Jay-Dev
[link] [comments]

News Reporter
News Reporter
Head of Operations (Banking), Director IT Governance, Teamlead Microsoft, Service Delivery Manager. Interested in Office 365, LAMP, IT Security and much more!