/// <summary> /// Attempt to print to the print wrapper /// </summary> /// <param name="s"></param> private void printS(string s) { if (_pw != null) { _pw.print(s); } }
private void _initClient() { try { var client = new TcpClient(IP, port); NetworkStream ns = client.GetStream(); byte[] bytes = Encoding.ASCII.GetBytes("Test Message!"); ns.Write(bytes, 0, bytes.Length); client.Close(); } catch (Exception e) { pw.print(e.ToString()); } }