Hi,
I am trying to disable all the plug-in steps under a plug-in because of one processing scenario. I am able to disable individually but I want to disable all the steps under the plug-in with one call. Is there any better approach other than below one. Below one is just a sample code to disable one step similar way I want to disable all the steps under that plug-in.
var qe = new QueryExpression("sdkmessageprocessingstep");
qe.ColumnSet.AddColumns("sdkmessageprocessingstepid", "name");
var step = orgService.RetrieveMultiple(qe).Entities.Where(x => x.Attributes["name"].ToString().Contains(pluginName)).First();
//Trying to retrieve but not sure how to update all the steps under this Step1 using one call
//var step1 = orgService.RetrieveMultiple(qe).Entities.Where(x => x.Attributes["name"].ToString().Contains(pluginName));
var pluginId = (Guid)step.Attributes["sdkmessageprocessingstepid"];
int pluginStateCode = enable ? 0 : 1;
int pluginStatusCode = enable ? 1 : 2;
orgService.Execute(new SetStateRequest
{
EntityMoniker = new EntityReference("sdkmessageprocessingstep", pluginId),
State = new OptionSetValue(pluginStateCode),
Status = new OptionSetValue(pluginStatusCode)
});
*This post is locked for comments