DevX Home    Today's Headlines   Articles Archive   Tip Bank   Forums   

Results 1 to 2 of 2

Hybrid View

  1. #1
    Join Date
    Mar 2006

    Exclamation Client server Question......Plz help

    Ok, so now ive got a server and 2 clients connected to it. On the server, i have data structures that hold the port and IP addresses of the clients and I guess a combination of these two can be used to differentiate the clients.

    now these clients are communication with the server. they input numbers, which go to the server and get stored in another datastructure.


    if client 1 inputs 1, i got to inform client 2 that client 1 has input 1

    the server is multithreaded offcourse.
    in other words, i want to send a message from one client to another, please help.

    note that i have got the clients getInetAddress and port numbers

  2. #2
    Join Date
    Feb 2006
    Cologne - Germany
    As I earlier pointed, there is an example of how to do that. I wrote an client/server chat application that does all of it. when client a sends a message it notifies the other clients of the new message. my the way: you don't need the ip/port of the clients. usually you have a stable connection between client and server, represented as input and outputstreams. when a client send something to the server, the server can use the outputstream to all other clients to send them that information.

Similar Threads

  1. SQL Server 2000 and Visual Basic Question
    By Eric Harris in forum VB Classic
    Replies: 2
    Last Post: 04-21-2002, 01:03 PM
  2. develpers needed for a revolutionary p2p network client
    By Patrick Lauber in forum Open Source
    Replies: 0
    Last Post: 03-07-2001, 10:52 AM
  3. Replies: 0
    Last Post: 12-17-2000, 01:02 PM
  4. Replies: 7
    Last Post: 09-15-2000, 08:44 AM
  5. Re: Disconnected RS - Client Question
    By Sergey in forum Enterprise
    Replies: 0
    Last Post: 03-24-2000, 06:30 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
HTML5 Development Center
Latest Articles
Questions? Contact us.
Web Development
Latest Tips
Open Source

   Development Centers

   -- Android Development Center
   -- Cloud Development Project Center
   -- HTML5 Development Center
   -- Windows Mobile Development Center

We have made updates to our Privacy Policy to reflect the implementation of the General Data Protection Regulation.