| Dart Home | PowerTCP Sockets for .NET | Custom Development | Reply | PowerTCP Sockets for .NET (Secure and Standard) Topics | Forums |
| Author | Forum: PowerTCP Sockets for .NET (Secure and Standard) Topic: UDP to VB Text Box |
| brianza brianza@compunet.com.mt From: Mosta, Malta Posts: 5 Member Since: 07/26/06 |
posted July 26, 2006 3:06 PM How can I convert a string received via UDP to a VB .net Text Box? |
| Amit From: Rome, NY USA Posts: 315 Member Since: 03/15/06 |
posted July 26, 2006 5:19 PM Hello, I have read your query and it is my understanding that you are looking to assign a String received via UDP to a vb.NET textbox. If this is the said scenario, then please note that you may try the following code snippet at your end: Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click Udp1.Open() End Sub Private Sub Button2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button2.Click Dim strSend As String = TextBox1.Text Udp1.Send(strSend, "10.64.1.160", 7) Dim da As Datagram da = Udp1.Receive(strSend.Length) TextBox2.Text = da.ToString() In case you are looking for a sample application to achieve the desired scenario, then you may mail me at amit.pal@dart.com. I hope this will be of help. In case of further assistance/ clarifications, please feel free to write back and I would be glad to assist you. Have a nice day ahead. Best Regards, Amit |
| brianza brianza@compunet.com.mt From: Mosta, Malta Posts: 5 Member Since: 07/26/06 |
posted July 27, 2006 1:23 AM This worked great! Now how can I leave my UDP session open so that it records anything comming in. |
| Amit From: Rome, NY USA Posts: 315 Member Since: 03/15/06 |
posted July 27, 2006 5:31 PM Hello, Regarding the query, please note that once the open method is called then a socket is allocated at an ephemeral port for sending and receiving datagrams. Till the time this socket is allocated to the UDP, you may record anything which is sent and receive. I hope this will be of help. Have a nice day ahead. Best Regards, Amit |
| Reply | PowerTCP Sockets for .NET (Secure and Standard) Topics | Forums |
This site is powered by
PowerTCP WebServer for ActiveX
|