The main message is that input/output arguments are available in the InputParameters/OutputParameters’ collections of PluginExecutionContext. Usage of Input argument The following code shows how to check that the Input Argument was passed and got value:
1 2 3 4 5 6 7 8 |
if (localContext.PluginExecutionContext.InputParameters.Contains("ArgumentName")) { string stringInputArgument = (string)localContext.PluginExecutionContext.InputParameters["ArgumentName"]; } else { //Your code for case when Argument was not passed } |
Usage of Output Argument The following code shows how to set the Output argument:
1 |
localContext.PluginExecutionContext.OutputParameters["OutputArgumentName"] = <Value>; |
One thing you should …