I have a plugin that is registered like this:
[CrmPluginRegistration(MessageNameEnum.Create, "contractdetail", StageEnum.PostOperation, ExecutionModeEnum.Asynchronous, "", "Post-Invoice Contract", 1, IsolationModeEnum.Sandbox)]
I am trying to update an attribute within the target entity like this:
//Update Contract Line StartDate Entity updatedContractLine = new Entity(entity.LogicalName) { Id = entity.Id }; updatedContractLine["activeon"] = startDate; service.Update(updatedContractLine);
I know that a PostOperation means that the created entity has already been committed to the database and I am fine with that. I want the "activeon" attribute to be updated after it is created. For some odd reason, the attribute is not updating! Can someone explain why?!