0

Trying to run a batch file and sending a parameter from ScriptBlock. And I am calling ScriptBlock from Start-Job command

$ScriptBlock = {
        param($file)
        E:\test\test.bat $file
    }

Start-Job -ScriptBlock $ScriptBlock  -ArgumentList $file

What should I do to run that test.bat file from ScriptBlock

SavindraSingh
  • 878
  • 13
  • 39
asim
  • 31
  • 1
  • 8

0 Answers0