I am working in a V9.0.3 environment.
I'm getting the following error when executing a visual script: 'No parameterless constructor defined for this object'.
The visual script consists of a 'for each loop' linked to a business object with a parameter.
Within the loop is a 'code activity' segment followed by an 'if else' segment. Both paths through the 'if else' segment have further 'code activity' segments.
If I move the two 'code activity' segments from the 'if else' segment into the first 'code activity' segment and manage them in code also removing the 'if else' segment', the error does not arise.
My question is; am I doing something wrong or should the original visual script work?
Incidentally, the reason for using the visual script is purely for clarity. All of the code segments are quite complex and I'm not going to be the person maintaining the process.