Chapter 29. Network Programming


  • Basic network programming topics

  • Communicating with network servers using the classes of the System.Net namespace

  • Creating sockets to create servers and clients

  • Using Internet Explorer in your applications

Just as it is difficult to live your life without talking with people, your applications also need to communicate, perhaps with other programs or perhaps with hardware devices. As you have seen throughout this book, you can use a variety of techniques to have your program communicate, including Windows Communication Foundation (WCF), .NET Remoting, Web Services, and Enterprise Services. This chapter looks at yet another way to communicate: using the basic protocols on which the Internet and many networks have been built. You will learn how the classes in the System.Net namespace can provide a variety of techniques for communicating with existing applications such as Web or FTP servers, and how you can use them to create your own network applications.

Before starting to write applications using these classes, however, it would be good to get some background on how networks are bolted together, and how machines and applications are identified.


No discussion of a network is complete without a huge number of acronyms, seemingly random numbers, and the idea of a protocol. For example, the World Wide Web runs using a protocol called Hypertext Transfer Protocol (HTTP). Similarly, there is the ...

Get Professional Visual Basic® 2010 and .NET 4 now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.