Powershell. Run powershell in python script.

preview_player
Показать описание

Рекомендации по теме
Комментарии
Автор

if you want to run multiple powershell commands do like this:

ipConfig = subprocess.check_output(
"PowerShell -Executionpolicy byPass
print(ipConfig.decode())

kanupriyalollmun
Автор

Hi Alex, Its a great approach.
How can we run PowerShell script in Python file
Example:
query = "PowerShell Query"
subprocess.call(["Powershell.exe", query])
Kindly, please help.
Thanks in Advance

vinodpasupuleti
join shbcf.ru