How do I call a powershell script from python but the ps script lies on a network drive?
Asked
Active
Viewed 167 times
-1
-
It's better to put research effort into a question before you blindly ask here! :) – L_Church Nov 26 '18 at 16:08
-
Not really, the thing is if I try to call the ps script from a Network drive, I am getting an error... or maybe im just doing it wrong :') – Filip Stanisic Nov 26 '18 at 16:09
-
Please [edit] the question to include both the code you've tried and the error message you were getting. – Jason Aller Nov 27 '18 at 03:19
1 Answers
2
Did you try?
import subprocess
subprocess.call("powershell \\path\to\script.ps1")

Nathan McCoy
- 3,092
- 1
- 24
- 46