This week's book giveaway is in the OCMJEA forum. We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line! See this thread for details.
Hi EveryBody, I am working on a intranet Messaging System which involves sending messages to valid users whose name and password is maintained in a database table.Now the whole scenario is something like this when the sender sends a message to a valid user he gets a form in which he types his username,his own name and the message, this calls a servlet which updates a database table and checks whether the user to whom he sends the message has currently logged in or not(This is accomplished when the user logs in he calls a servlet which sets a flag in a databse table which contains valid username, password and a flag,this flag is set to on).Once he checks that the user has logged in he stores this information in a flat file which resides on the server.This file contains the username to whom the mesage is send, and a flag stating whether a particular message is read on not. Now I need to pop up a message to the sender everytime he recieves a new message.For this whenever the sender logs in his flag is set on on the databse table and then he has to "READ THIS FILE CONTINOUSLY , WHENEVER HE CHECKS ANY ENTRY OF HIS NAME IN THIS FILE,IT HAS TO PROMPT A MESSAGE SAYING U HAVE NEW MAIL"something what we get in a yahoo or any chat application. Please suggest me best possible ways to achieve this, my limitation is I can't use an applet(otherwise life wd have been easier for me) Thanking u all in advance.