private void AddServer(string strHost, UInt16 iu16Port, string strUsername, string strPassword, bool blConnect) { PRoConClient prcClient = this.m_paProcon.AddConnection(strHost, iu16Port, strUsername, strPassword); if (blConnect == true && prcClient != null) { prcClient.Connect(); } }
public void CreateConnection(string hostName, string port, string username, string password) { ushort parsedPort = 0; if (ushort.TryParse(port, out parsedPort) == true) { PRoConClient newConnection = this.m_proconApplication.AddConnection(hostName, parsedPort, username, password); if (newConnection != null) { newConnection.Connect(); } } }