Web Service > Web Service Operations > Working with Processes > SetStartEventSettings
Result SetStartEventSettings(BpmProcessId tBpmProcess, BpmStartEventInfo tArg)
tBpmProcess. Moniker of opened process.
tArg. Operation execution parameters.
The SetStartEventSettings operation changes process start event settings.
To execute the operation, in the tBpmProcess field specify moniker of opened process, and in the tArg field specify settings to be determined. Depending on the value of the tArg.optType field, different groups of fields are set. The moniker can be obtained after executing the OpenBpmProcess operation.
The operation returns whether start event settings were determined successfully.
Below is the example of changing process start event settings. The request contains moniker of opened process and settings to be determined. The response contains whether settings were changed successfully.
{
"SetStartEventSettings" :
{
"tBpmProcess" :
{
"id" : "DICNGBKNAJKEGOAEPFPJHGAAEMHJPFIEHLGHCIACBBLCJJKA!M!S!BPAHEICDKNAJKEGOAECMEPDJAJDGAPEBCELJDMNJMLEPENHPHE"
},
"tArg" :
{
"optType" : "0",
"per" :
{
"type" : "Monthly",
"mPer" :
{
"ms" :
{
"it" :
[
"1",
"2",
"3",
"4",
"5",
"6"
]
},
"dM" :
{
"d" : "15"
}
}
},
"rep" : "6"
}
}
}
{
"SetStartEventSettingsResult" : "1"
}
public static bool SetStartEventSettings(string moniker)
{
var somClient = new SomPortTypeClient(); // Proxy object for operation execution
// Operation execution parameters
var tSet = new SetStartEventSettings()
{
// Create object moniker
tBpmProcess = new BpmProcessId() { id = moniker },
tArg = new BpmStartEventInfo()
{
optType = 0,
per = new BpmPeriodInfo()
{
type = BpmSchTaskPeriodType.Monthly,
mPer = new BpmSchTaskPeriodMonthly()
{
dM = new BpmSchTaskPeriodMonthlyModDay()
{
d = 15
},
ms = new int[6] { 1, 2, 3, 4, 5, 6 }
}
},
rep = 6
}
};
// Determine start event settings
var result = somClient.SetStartEventSettings(tSet);
return result;
}
See also: