"Resolution Stage" ignored by an Agent when using Flow-New, case still open after flow was processed
I have a problem with my agent and the associated activity.
The activity is basically doing the following:
Obj-Open of a case
Flow-New of a resolution stage (which is an alternate stage)
Obj-Save (with write now for test purpose)
When I run my activty manually, it's working perfectly: the case is getting closed and the pending tasks are closed as well.
But when the agent runs it, it doesn't work: it processes the stage well, but when it reaches the end shape, it doesn't close the case and the Flow-New terminates ignoring the fact that the stage was actually a resolution stage. Hence, the stage remains open and so do the open tasks on it.
On the security tab of my agent, I put an Administrator AccessGroup and ticked the box below. I tried with a blank AccessGroup and with the box ticked, with the same result.
To sum it up: my agent executes a Flow-New step normally but ignore that the flow is a resolution stage, leaving it open after the flow was processed instead of closing it.
Any ideas for this please?
Thanks in advance.
Update: I know that a solution could be to call pxForceCaseClose, but I would like a cleaner solution if there is one! Thanks in advance.