Click here to Skip to main content
15,886,622 members
Please Sign up or sign in to vote.
1.00/5 (3 votes)
See more: , +
Used Tutorial[^]
I have successfully create a program that the Client Send Data to server.
Can someone show me a sample that the Server will send data to Client

Thanks..

I've search it in Google but result is same as sending data from Client to Server
Posted
Comments
kbrandwijk 4-Sep-14 19:51pm    
Post some code. What have you tried? Where do you get stuck? What are the symptoms, errors, exceptions?
hansoctantan 5-Sep-14 3:26am    
My code is same as the link, I can now send Data from Client to Server.
What I want it the server will send Data to Client.

1 solution

Even in pure (and poor, very limiting :-)) client-server model, server nearly always sends data to client: client sends request and then the server sends response. This pair, client + server, is absolutely symmetrical in terms of direction of the data flow. It is asymmetrical in terms of connection: it is performed by the client, which is connected to the server listening for the connection.

I don't know what samples should be shown here; this is all pretty much trivial.

For some ideas, please see my past answers:
an amateur question in socket programming[^],
Multple clients from same port Number[^].

For some background, please read:
http://en.wikipedia.org/wiki/Client-server[^],
http://en.wikipedia.org/wiki/Pull_technology[^],
http://en.wikipedia.org/wiki/Push_technology[^].

The problems of limitations of client-server are very serious, but they are not like the problem of the direction of data flow. Please see my past answer where I try to explain it all: Application 'dashboard' for website accounts[^].

—SA
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900