Jump to content

run() openvpn and $STDOUT_CHILD -> openvpn doesn't start at all


Recommended Posts

My script looks like this:

#include <Constants.au3>
Run('"C:\Program Files\OpenVPN\bin\openvpn.exe" "D:\config\tunnel.ovpn"','C:\Program Files\OpenVPN\bin\',@SW_SHOW, $STDERR_CHILD + $STDOUT_CHILD)

which opens a DOS Window and closes shortly thereafter without actually starting OpenVPN.

Run('"C:\Program Files\OpenVPN\bin\openvpn.exe" "D:\config\tunnel.ovpn"','C:\Program Files\OpenVPN\bin\',@SW_SHOW)

works like intended.

What am I doing wrong ?

Edited by level20peon
Link to comment
Share on other sites

It didn't make a difference.

Edit:

I created a workaround for now but if anybody knows how to get a handle on my original code I would be pleased to learn about it.

workaround:

$run = Run('cmd.exe','D:\config\',@SW_HIDE,1+2+4)
StdinWrite($run,'"C:\Program Files\OpenVPN\bin\openvpn.exe" "D:\config\tunnel.ovpn"' & @CRLF)
Edited by level20peon
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...