When you run a batch file using a PowerShell script in Application Services, the script might not run but the task completes successfully.

The PowerShell script in Application Services is not running.

The PowerShell script might need an expression to run successfully.

Add an invoke-expression expression to the PowerShell script.

For example, to start and stop a Windows vFabric tc Server, type invoke-expression $service_stop and invoke-expression $service_start expressions to the script.