Best practices: File transfer tcp/ip (VB.NET 2015 + SQL Server 2008) RRS feed

  • Question

  • Hi. Firstly thanks for your time. I'm working on a project that needs to send one or more files through the lan network under tcp/ip protocol. I readed a lot in different forums of this topic but i don't sure how is the best practice to make it.
    I would appreciate your recommendation or sayme the difference between the differents ways (TCP Listener, Socket, another)
    ..  to hold the tcp port listening or only open it to the transfer... etc)
    Thanks so much
    Thursday, July 26, 2018 11:14 AM


  • Hi

    Use TCP to transfer files, you can use sockets for transmission, or use the TcpLister class and TcpClient class for transmission. In fact, TcpLister and TcpClient are the socket-encapsulated classes, and .NET encapsulates the sockets in order to simplify programming complexity. However, TcpLister and TcpClient only support standard protocol programming. If you want to write a program that is not a standard protocol, you can only use a socket socket.

    Best Regards,


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact

    • Marked as answer by CM16 Monday, July 30, 2018 4:57 PM
    Friday, July 27, 2018 5:20 AM