i have a script to run and he works fine when i use that on PowerShell ISE, but i need to run at .ps1 file (double clicking) and when i try this, hothing happen... the powershell's window opens but my script dont run.
my code is:
$path = "W:\Processos\Integracao\Titulos Carrefour"
$path2 = "\\fileserver\departamentos$\Matriz\Titulos Carrefour"
Set-Location $path
Get-ChildItem -Path "$path2\*.csv" -Recurse | Move-Item -Destination $path -Force
Start-Process 'winscp.com' -ArgumentList /script=envio.scp -Wait