Issue Description
Adding user or group fields from two or more SharePoint List SmartObjects as destination users in a SharePoint User task will fail with an error at deployment.

Error Message
System.InvalidOperationException: The item can not be added to more than one collection.
   at SourceCode.Framework.PersistableObject.set_Container(PersistableContainerObject value)
   at SourceCode.Framework.PersistableObjectList`1.Add(T item)
   at SourceCode.Workflow.Design.Input..ctor(String name, String displayname, String type, Boolean isRequired, Boolean isList, Boolean isUnique, K2Field[] values)
   at SourceCode.Workflow.Design.Input..ctor(String name, String type, Boolean isRequired, Boolean isList, K2Field[] values)
   at SourceCode.WebDesigner.Authoring.Forms.GenerateProcess.DoSPWrapping(Activity newActivity, XmlDocument inputData, String[] ConfigValues, String dynamicTypeForDestinationItem, K2Field currentField, SmartObjectFieldPart soFieldPart)
   at SourceCode.WebDesigner.Authoring.Forms.GenerateProcess.CreateDestinations(XmlNode activity, Activity newActivity, XmlDocument xmlProcess, Process newProcess)
   at SourceCode.WebDesigner.Authoring.Forms.GenerateProcess.CreateActivies(XmlDocument xmlInputData, XmlDocument xmlProcess, DefaultProcess& newProcess, String UserName)
   at SourceCode.WebDesigner.Authoring.Forms.GenerateProcess.Generate(String LocalHostConnection, String UserName, Int32 ProcessID, String InputData, String ProcessXML, String SqlConnectionString, String HostServerConnectionString)

Image

Resolution

  1. Ensure you have K2 4.7 installed.
  2. Install the K2 4.7 February 2017 Cumulative Update.
  3. Get the K2 4.7 February 2017 Cumulative Update FP6 from Regional Support.
  4. Install the K2 4.7 February 2017 Cumulative Update FP6 to apply the fix.
  5. Clear the Browser cache.