Run Powershell Actibity never completing

WHen I try to run the following PowerShell it keeps running infinitely without completing.
Does anyone have an idea what is going wrong?

Hi @JMA,
Are you using Invoke PowerShell activity?

Hi @Pablito , No I’m using the UiPath script activies ‘Run PowerShell Script’

I am also trying with the Invoke PowerShell but doing it that way I can not seem to figure out how to capture the output.
I am always getting the error compiler error encountered processing expression: output type PSObject is not defined:

Please take a look on this. Maybe it will help :slight_smile:

1 Like

Enable “Isscript” and also change to “string”.




Changing the TypeArgument & enabling the IsScript indeed did solve my problem !


I had the same issue in the past, I’m glad I was able to help. Please mark it as solution for others that have the same problem in the future are able to find it. Thank you. :slight_smile:

1 Like

This topic was automatically closed 3 days after the last reply. New replies are no longer allowed.