Only on Experts-Exchange: Sign-up for a free-trial and we'll send you your permanent license!
Here is what you get: 30 Nodes | Unlimited Sensors | No Time Restrictions | Absolutely FREE!
Act now. This offer ends July 14, 2017.
postData = "\x00\x81SV.97000000009\x1C123456"; var server = "localhost"; var port = 5100; TcpClient client = new TcpClient(server, port); byte bytes = Encoding.ASCII.GetBytes(postData); NetworkStream stream = client.GetStream(); stream.Write(bytes, 0, bytes.Length); bytes = new Byte; String responseData = String.Empty; Int32 data = stream.Read(bytes, 0, bytes.Length); responseData = Encoding.ASCII.GetString(bytes, 0, data); var result = responseData; stream.Close(); client.Close();
Add your voice to the tech community where 5M+ people just like you are talking about what matters.
Join the community of 500,000 technology professionals and ask your questions.