Hi CRM Community,
In Dynamics CRM version 8.1 we have the following code working without any problem: it creates an AccessTeam
- entity - comes as a parameter - type Entity
var bu = "the root Business Unit";
var team = new Team
{
Name = "My Custom Access Team Name",
TeamType = new OptionSetValue((int)TeamTeamType.Access),
AdministratorId = new EntityReference(SystemUser.EntityLogicalName, _Context.UserId),
BusinessUnitId = new EntityReference(BusinessUnit.EntityLogicalName, bu.Id),
};
team.RegardingObjectId = entity.ToEntityReference();
team.Id = _Service.Create(team);
As with the version 8.2.2 we cannot use the RegardingObjectId any more - we get the following error message:
[6ad6d959-295c-e711-80e6-005056892d2b: 40_opportunity_create]
Exception: System.ServiceModel.FaultException`1[Microsoft.Xrm.Sdk.OrganizationServiceFault]: Only system managed teams can associated with team templates or other records. They can only be created by the system. (Fault Detail is equal to Microsoft.Xrm.Sdk.OrganizationServiceFault).,
We need the AccessTeam created with a specific Name format and the regardingObjectId defined!
If we let the system create the AccessTeam, we cannot change it's name :(
Could anyone give us a helping hand and explain why this happens?
Thank you in advance for your help!
*This post is locked for comments