DelphiFAQ Home Search:



Databases
InterBase, MS-SQL, mysql, Oracle
Programming
C#, C++, Delphi, Java,
JavaScript, perl, php, Visual Basic, VBScript
Linux
Apache, Network, Shell
Web Publishing
JavaScript, perl CGI, VBScript, Web Hosting
Windows
Apache, File Types, Internet Explorer,
Network, Printing, Processes
Outside the Cube
Auto, Computer Hardware,
Finances, Dating Scams,
Household, Male Dating Scammers,
Other Scams, Travel

Featured Article

Client / Server programming - generic steps to start a server or a client

Client/server network programming requires a server running on one machine to listen and answer requests and one or more clients running either on the same machine or different machines connected to the server through a network.

Independent from your operating system and programming language, you'll have to follow the following basic steps to create and run a server (the function refers to the unix naming convention; almost all languages have interfaces to them):

  1. Create a socket with socket
  2. Bind the socket to a port address with bind
  3. Listen to the socket at the port address with listen
  4. Accept client connections with accept

Creating a client involves less steps:
  1. Create a socket with socket
  2. Connect the socket to the remote machine with connect


Most modern environments offer classes, components, beans, Active-X controls.. libraries.. to abstract this process but it's good to know the basic steps that happen behind the scenes in case you get an error message 'Cannot bind socket'.. 'port already in use'.


Generated 0:02:45 on Aug 18, 2017