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

Problem

The PowerShell script in Application Services is not running.

Cause

The PowerShell script might need an expression to run successfully.

Procedure

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.