I have Dynamics CRM 2011 plugin (retrieve, post-action) which should simply set the value of custom field when retrieving Contact entity:
public void Execute(IServiceProvider serviceProvider)
{
IPluginExecutionContext context = PluginExecutionContext)serviceProvider.GetService(typeof(IPluginExecutionContext));
if (context.OutputParameters != null)
{
Entity entity = (Entity)context.OutputParameters["BusinessEntity"];
if (entity.Attributes.ContainsKey("new_markerexists") == false)
return;
entity["new_markerexists"] = "Marker exists.";
However, CRM plugin can not find this or any other custom field. It works fine with the standard fields.
What am I missing here?
Thanks!