Thursday, September 23, 2010

How to fire a Workflow through Plugin

ExecuteWorkflowRequest request = new ExecuteWorkflowRequest();

//Assign the ID of the workflow you want to execute to the request.

request.WorkflowId = new Guid("stringWorkFlowid");

//Assign the ID of the entity to execute the workflow on to the request.

request.EntityId = id;

// Execute the workflow.

ExecuteWorkflowResponse response = (ExecuteWorkflowResponse)service.Execute(request);

No comments:

Post a Comment