The command I was using: powershell.exe -noexit 'filename.ps1' It only requires single >quotes if there's a space in the path to the file name. I removed the single quotes and for >some reason this worked. I don't quite understand why it worked though...
Ao colocar as aspas, sua saída só retorna o texto citado. Se você comandou assim:
powershell.exe -noexit & 'filename.ps1'
ele executaria o script porque tem um operador de Chamada (&)
Is there a way to run the powershell.exe command in a batch file as admin? It defeats the >purpose of mass automation if I have to right click it and run as admin.
A execução de um arquivo de lote que executa um script parece intuitiva ... Qual a capacidade que você está tentando executar o script?