If ComboBox1.Text = "" Then MsgBox("Select server file from combobox", MsgBoxStyle.OkOnly, "error") Else openvpnProcess.StartInfo.CreateNoWindow = True If CheckBox1.Checked = True Then openvpnProcess.StartInfo.WindowStyle = ProcessWindowStyle.Normal Else openvpnProcess.StartInfo.WindowStyle = ProcessWindowStyle.Hidden End If openvpnProcess.EnableRaisingEvents = True openvpnProcess.StartInfo.Arguments = "--config " & Me.ComboBox1.SelectedItem & "" openvpnProcess.StartInfo.FileName = "C:\Program Files\OpenVPN\bin\openvpn.exe" openvpnProcess.StartInfo.WorkingDirectory = "C:\Program Files\OpenVPN\config\" openvpnProcess.Start()
Dim uriAddress1 As New Uri("https://www.xxxx.com/ovpn/xxxx/xxxxxxxcom_TCP.ovpn") TextBox2.Text = uriAddress1.LocalPath
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)