如何在VB.NET应用程序中的同一端口上发送和接收TCP数据? [英] How to send and receive TCP data on same port in VB.NET applicaton?
问题描述
您好,我想从我收到数据的同一个端口发送数据。
例如。我使用UNOLibs制作了tcp监听器。所以接收和发送工作正常。但问题是,如果我收到6666端口的数据,那么我需要从端口号回复。 6666.我无法找到方法。
基本上我需要在同一个源和目标端口上回复收到的包含相同源和目标IP的包。
请帮忙。
我尝试过:
使用UNOLibs简单发送和接收tcp数据
Hello, i want to send data from the same port on which i have received the data.
for eg. i have made tcp listener using UNOLibs. so for receiving and sending is working ok. But the problem is if i receive data on port no 6666 then i need to reply from port no. 6666. i cannot find out the way to do it.
Basically i need to reply to received package with same source and destination ip on same source and destination port..
Please help.
What I have tried:
Used UNOLibs to make simple send and receive tcp data
推荐答案
Code Project上有很多文章涉及这个主题: TCP - CodeProject搜索 [ ^ ] - 选择一个。
There are plenty of articles right here on Code Project that cover this topic: TCP - CodeProject search[^] - Pick one.
这篇关于如何在VB.NET应用程序中的同一端口上发送和接收TCP数据?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!