| Methods / Methods for Process Instances | |
Web Services
Creates a process instance that can have additional input arguments added to the function.
public virtual WFEvent CreateProcInstEx(string ProcessID, string ProcessInstID, string ProcInstName, string WorkObjID, string SuperProcInstID, string CustomID, NameValue[] Attributes, bool blnstartImmediately)
| Name | Description |
|---|---|
ProcessID |
|
ProcessInstID |
|
ProcInstName |
|
WorkObjID |
|
SuperProcInstID |
|
CustomID |
|
Attributes |
|
blnStartImmediately |
|
WFEvent object that provides the status of the transaction. The possible statuses are:
IWFWorkflowService svc = GetWorkflowService();
string processDefinitionName = "EmployeeOnboardProcess";
// get UUID of released process definition
string ProcessID =
svc.GetReleasedPID(processDefinitionName);
// assign UUID of process instance
string ProcessInstID = UUID.GetID();
// process instance name that has to be unique within process definition ID
string ProcInstName = string.Format("{0}-{1}",
processDefinitionName DateTime.Now.Ticks );
// work object ID
string WorkObjID = UUID.GetID();
//parent process instance ID is required if this is to create a sub
process. If not, just provide null
string SuperProcInstID = .. // for example,
"09315f0ae769429bbfb243f888bcb09f" or null
List<NameValue> ds = new List<NameValue>();
ds.Add(new NameValue("CustomAttrKey1", "CustomAttrValue1"));
ds.Add(new NameValue("CustomAttrKey2", true));
ds.Add(new NameValue("CustomAttrKey3", 12345));
WFEvent evt = svc.CreateProcInstEx(
ProcessID,
ProcessInstID,
ProcInstName,
WorkObjID,
SuperProcInstID,
WorkObjID,
ds.ToArray(),
true);
3.2.0.4 and higher