C++ client server application

Hi guys!

i want a client server application for sending simple message in C++. i don't need the code i'll work on it just need direction to focus my effort on right direction.

suppose i have method message on server and want to invoke from client to see the messages, what files do i need to have

1
2
3
4
5
6
7
void message{
                cout<<"hello world"<<endl;
}
int main(){

        message();
}


i want to invoke function message from client.

my question, which files do i need to have

client,server,socket just file i'll work down my own

Regards,

Ewa
Last edited on
Typically, the server listens for incomming connections. When a client want's something from the server it connects to it, sends a request and receives a reply.

The actual details of the exchange is what we call 'the protocol'. You'll end up with one either way, but it's best to think about the request/reply as part of your design.
It sounds like you'll want to look into a 3rd party library to facilitate communication for your model. Consider something like ACE or Boost:Asio.
Hello kbw and moorecm!

thanks for your help, it was really fruitful

Regards,

Ewa
Hi Ewa,

Please read my post about making a client/server application.

http://rsnichnetwork.blogspot.com/2012/05/good-solution-to-make-clientserver.html

Regards,
rsnich
Topic archived. No new replies allowed.