I’m creating a Power Shell Script that runs as expected when executed directly in Power Shell. However, when I try to run it using the Invoke Power Shell activity in UiPath, I encounter an error. Please find the error details and screenshot attached.
ERROR: Invoke Power Shell: The ‘Get-Printer’ command was found in the module ‘PrintManagement’, but the module could not be loaded. For more information, run ‘Import-Module PrintManagement’.