Powershell
-
- Posts: 8
- Joined: 25 Sep 2019 15:18
Powershell
Is it possible to trigger/launch a powershell script using the commands? For instance when I stop recording I trigger a powershell script that updates the recorded file to another folder or the cloud?
Re: Powershell
Yes, see the control-commands in the Appendix of the User Manual.
For example see the EXEC_SHELL_COMMAND or EXEC_SHELL_COMMAND_SYNC command.
You can e.g. use the event system of the Mixer channel to trigger such command (right-click on the mixer channel name and select Edit Control Command Events...).
For example see the EXEC_SHELL_COMMAND or EXEC_SHELL_COMMAND_SYNC command.
You can e.g. use the event system of the Mixer channel to trigger such command (right-click on the mixer channel name and select Edit Control Command Events...).
Bernd - radio42
ProppFrexx ONAIR - The Playout and Broadcast Automation Solution
ProppFrexx ONAIR - The Playout and Broadcast Automation Solution
-
- Posts: 8
- Joined: 25 Sep 2019 15:18
Re: Powershell
Ok, I am struggling to get it to work. Maybe it is a format issue
My call is now:
EXEC_SHELL_COMMAND Copy-Item C:\Users\Playout\Music\Interview.mp3 -Destination C:\Temp|normal
It does not work at the momennt, could you help me with it?
My call is now:
EXEC_SHELL_COMMAND Copy-Item C:\Users\Playout\Music\Interview.mp3 -Destination C:\Temp|normal
It does not work at the momennt, could you help me with it?
Re: Powershell
Try:
EXEC_SHELL_COMMAND powershell.exe Copy-Item "C:\Users\Playout\Music\Interview.mp3" -Destination "C:\Temp"|normal
EXEC_SHELL_COMMAND powershell.exe Copy-Item "C:\Users\Playout\Music\Interview.mp3" -Destination "C:\Temp"|normal
Bernd - radio42
ProppFrexx ONAIR - The Playout and Broadcast Automation Solution
ProppFrexx ONAIR - The Playout and Broadcast Automation Solution
-
- Posts: 8
- Joined: 25 Sep 2019 15:18
Re: Powershell
Still does not work. Could you give an example that does work? Maybe I can figure it out. Does it need any quotes?
Re: Powershell
I corrected the above, it must actually be powershell.exe to start it.
Note, that the EXEC_SHELL_COMMAND effectively just launches any OS application, so the first parameter argument must be powershell.exe to start powershell itself and then followed by the command-line arguments to pass to that application.
E.g.:
EXEC_SHELL_COMMAND powershell.exe Copy-Item "C:\Users\Playout\Music\Interview.mp3" -Destination "C:\Temp"|normal
Note, that the EXEC_SHELL_COMMAND effectively just launches any OS application, so the first parameter argument must be powershell.exe to start powershell itself and then followed by the command-line arguments to pass to that application.
E.g.:
EXEC_SHELL_COMMAND powershell.exe Copy-Item "C:\Users\Playout\Music\Interview.mp3" -Destination "C:\Temp"|normal
Bernd - radio42
ProppFrexx ONAIR - The Playout and Broadcast Automation Solution
ProppFrexx ONAIR - The Playout and Broadcast Automation Solution