The commad below in quotes works from the PowerShell command line, but not in a script I have assigned to a button. I also "Tried" the script, and there are no errors. Any idea why it's not working?
runret("C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe C:\Users\bernie\PowerShell\processphotos.ps1");
PowerShell script works from command line but not in XYplorer script
-
zBernie
- Posts: 181
- Joined: 08 Dec 2016 17:20
-
jupe
- Posts: 3478
- Joined: 20 Oct 2017 21:14
- Location: Win10 22H2 120dpi
Re: PowerShell script works from command line but not in XYplorer script
runret() gives a return, unlike run(), so you need to give it something to return into, like a variable or another command etc, try this instead:
Code: Select all
text runret("C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe C:\Users\bernie\PowerShell\processphotos.ps1");
XYplorer Beta Club