Menu
Menu
DaniWeb
Log In
Sign Up
Read
Contribute
Meet
Search
Search
About 29 results for
multichat
- Page 1
Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by Vegito1991
… solve this problem for few days, i was working on
multichat
application where in this class i want to send the…
Re: Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by JamesCherrill
That's not enough of the code to see why a variable should still be null, but for starters try printing `out` and `txtmsg` just before that line to see which is null.
Re: Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by Vegito1991
i have using Joption to check and the > out in the actionperformed was null
Re: Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by JamesCherrill
Unless there's a duplicate declaration of out somewhere, that implies that the `actionPerformed` has been called before `run` gets to line 61. Maybe it's hanging on the `new Socket` or maybe it's thrown an IOException (because I can't see any code to handle that Exception)
Re: Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by Vegito1991
For more information, i wonder the duplicate declaration u mean which point to both IP checking page and Client class? login page public class MyChatLogin extends javax.swing.JFrame { private Connection con; private PreparedStatement st; private ResultSet rs; private String driver = "sun.jdbc.odbc.JdbcOdbcDriver";…
Re: Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by Vegito1991
i have found the problem, seems like because i using new object to open the jframe and this new object has cause my out become null, any idea how to open new jframe without lose its value?
Re: Need help for the multichat application with client and server
Programming
Software Development
10 Years Ago
by JamesCherrill
I'm sorry, but you have posted hundreds of lines of undocumented code with no apparent overall structure, multiple main methods, multiple declarations of variables with the same name, code that refers to variables that are not declared in that class, and I have absolutely no idea what the flow of control is to ensure everything is initialised …
Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
I have assigned to create a
multichat
application that require to public message to all client, private …
need multichat code using php
Programming
Web Development
16 Years Ago
by senthil_kumar
anybody known well in php , plz help me .i need multichatting script using php and mysql
Re: need multichat code using php
Programming
Web Development
16 Years Ago
by danishbacker
Do you mean ajax chat? If so check this link [url]http://www.php-development.ru/javascripts/ajax-chat.php[/url] You can get many like this by googling "ajax chat using php"
Re: need multichat code using php
Programming
Web Development
16 Years Ago
by danishbacker
[url]http://www.phpfreechat.net/[/url] [url]http://www.google.co.in/search?hl=en&q=ajax+chat+using+php&btnG=Google+Search&meta=&aq=f&oq=[/url]
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
Correction... basically i able to run through localhost and ip address, and also chat with multi clients, So if anyone can tell me which part should i do to implement private msg and online user list (where will show the name after client access the server, and remove the name when client close), i really appreaciate
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Taywin
My simple answer is to ignore the coding part for now and look at how this application model works. You need to be able to look at the code (and this one is very small), and then create something like a flow chart. Once you have the model (flow chart), then you will see how you can insert what you want into the flow chart. The coding part (…
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by JamesCherrill
What you are asking for is a lot simpler than the code you already have, so why are you finding it difficult? (You did write that code from scratch, didn't you?) Maybe if you explain exactly why you are stuck then we will know how best to help you.
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
Because i still a beginner for socket programming and mostly i was refering online tutorial to solve the problem, i do understand how the message transfer after following the solution, however i still can't figure it out how to implement private message, for you might easy but for me is harder, i'm the person who read coding and do debugging to …
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
OK, the things that i want to solve is, i using `txtmsg.addActionListener` to chatting just by entering after text typing, without `button`. I have jlist in my client side, where have "All" and other User Name that only appear after they login, if i select All, then send message to all clients, which i already solved. Now is, i want to …
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by stultuske
you have code like this: catch (Exception ex) { } this: catch (Exception ex) { chatTextArea.append("Message was not sent. \n"); } and this: catch (Exception ex) { System.err.println("Error telling everyone."); } I'm not surprised you're having trouble finding all the things going wrong. …
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
do you mean using print stack trace is better?
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by stultuske
absolutely. especially if you need to update/improve your code. you shouldn't print it to the ui, but putting it on the command prompt or in a log is always a good idea. it'll tell you what went wrong, and on which line of the code the exception was thrown.
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
i have apply to any place that is neccessary, however, i still need some guide on which part of the coding that should i focus to implement the private message? Can give me some example? and anythings that should i involved for the implementation?
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by stultuske
what do you mean? you should focus on the code to send a private message. what exactly do you mean? it's your code (I assume) and your analysis, so you should be the one being able to tell us that.
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
what i mean is what should i use, based on the online references, they are using for loop to get the username, although coding differents, `like vector and array, printstream and printwriter` this is one of the example that i found, but totally different with mine public ServerThread findUserThread(String usr){ for(int …
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
In my code, i have stored the connected user in clientOutputStreams as ArrayList, below codes is where i send message to all clients at contained inside the list by the coding below public void tellEveryone(String message) { // sends message to everyone connected to server Iterator it = clientOutputStreams.iterator();…
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
i had tried this but not working `tellSomeone(data[3], message);` while (it.hasNext()) { try { if (it.next().equals(name)) { Object obj = it.next().equals(name); PrintWriter writer = (PrintWriter) obj; writer.println(message); writer.…
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by stultuske
"but not working" is a lousy description. what is not working? don't you get the expected results? is there an exception thrown? is there a stacktrace? do you get an unexpected result? did you debug? does it even go through the loop?
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
i have use System.out.println(obj) to check if can display the users, and yes it is, however, i have change the coding and the message that i send still cannot display in the receiver's screen. lets says receiver is data[0] where stored Boyz in the Arraylist (clientOutputStreams) has Boyz and Gary i want using Gary to send message to Boyz and the…
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by stultuske
indeed, your problem is here: Object obj = it.next().toString().equals(name); System.out.println(obj); PrintWriter writer = (PrintWriter) obj; looks like you are trying to cast the wrong reference variable to a PrintWriter or ... what exactly are you tring to print?
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by Vegito1991
yeah, i just found i should not do that, and i want to ask since my `data[0]` is `String`, is it able to search the name in `ArrayList` by using `toString()`? or in order to send private message, it always better to use index? i really out of idea to solve this problem and today i spend whole today and can't even figure it out. Should i use string…
Re: Online user list and private message problem
Programming
Software Development
10 Years Ago
by stultuske
well, I'm still not entirely clear what you're trying to do. most likely you want to contact the one with the ID of the person you're trying to reach, so the String
Search
Search
Forums
Forum Index
Hardware/Software
Recommended Topics
Programming
Recommended Topics
Digital Media
Recommended Topics
Community Center
Recommended Topics
Latest Content
Newest Topics
Latest Topics
Latest Posts
Latest Comments
Top Tags
Topics Feed
Social
Top Members
Meet People
Community Functions
DaniWeb Premium
Newsletter Archive
Markdown Syntax
Community Rules
Developer APIs
Connect API
Forum API Docs
Tools
SEO Backlink Checker
Legal
Terms of Service
Privacy Policy
FAQ
About Us
Advertise
Contact Us
© 2025 DaniWeb® LLC