Exit codes from shell and powershell
In our Workflow process we are using the component "Execute Process and wait" to run powershell.exe with arguments.
This is running successfully. The problem we are having is retrieving the %errorlevel% from the powershell completion. In our powershell scripts, we are exiting with specific errorcodes depending on what has been done. We want workflow to retrieve this value and then carry out specific workflow based on the return code.
When I manually run the powershell script from a windows command prompt and then echo %errorlevel%, upon completion I can see that powershell is correctly exiting with the required exitcode.
How do I get Workflow to retrieve the %errorlevel% this is not either "Standard Output" or "Standard Error".
I can't believe that workflow wouldn't be able to do this basic function. I must be using the incorrect component.
Thanks for you help