How do u write a server to open or close ports ???
and then use a client to access the server????
if the code is short plz post it on this forum
Printable View
How do u write a server to open or close ports ???
and then use a client to access the server????
if the code is short plz post it on this forum
You can use the Winsock control to write server- and client-applications.
If you have access to MSDN, you can look up how to use this control (or search on the Microsoft site). It's described both for server and client applications. The examples aren't that helpful though, but using the Winsock isn't that hard either.
The code is too long to post here, since many events will occur and you will need to handle them all properly.
If you're making a server app, set the index property of the control to 0 and load a new instance when a new connection arrives.
I hope this will help