Java Forums

Main Menu
Home
Today's Posts
FAQ
Search
Contact Us

Java Network
Linux Archive
Java Tips
Java Tips Blog

Sponsored Links





Welcome to the Java Forums.

You are currently viewing our boards as a guest which gives you limited access to view most discussions and access our other features. By joining our free community, you will:

  • have access to post topics
  • communicate privately with other members (PM)
  • not see advertisements between posts
  • have the possibility to earn one of our surprises if you are an active member
  • access many other special features that will be introduced later.

Registration is fast, simple and absolutely free so please, join our community today!

If you have any problems with the registration process or your account login, please contact us.

Reply
 
LinkBack Thread Tools Display Modes
  #1 (permalink)  
Old 08-03-2007, 07:40 AM
Member
 
Join Date: Aug 2007
Posts: 5
garinapavan is on a distinguished road
Urgent-Imp-Displaying message with respect to system time
I have a table (TimeTable) in database and column name is Current time:

Table Name: TimeTable


TimeTable
CurrentTime

03.00.00.000000 AM
04.00.00.000000 AM
05.00.00.000000 AM
10.00.00.000000 AM
12.00.00.000000 PM



Now My java Program should do the following:

Reading the data from the database.

And Now pick up the time from table and when the time matches with the system time
it need to trigger or dispaly a message "Hello".This should happen with all the records
in the table with respect to their time.

If i take the above database table as example:

At 3'o clock it has to display "Hello" and again 4'o clock
again it has dispaly "Hello". Like this it has to happen for the rest of the
rows also.

Provide me the answers for the below questions



1)Help me with this kind of code where i can schedule and trigger the message for display.
2) The Program should run always and it should look up the system time and
display the message when ever the time occurs.





Pavan
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
  #2 (permalink)  
Old 08-03-2007, 04:17 PM
Senior Member
 
Join Date: Dec 2006
Posts: 748
levent is on a distinguished road
You can access your database table with JDBC.

When you initially launched your program, it will get the nearest alarm time from table and remove it from the table. You will start a timer to launch a specific event at the fetched alarm time. And after that timer is executed, you will fetch the next alarm time from database and restart a timer.

For timer functionality, check Timer class in Java SE.
Bookmark Post in Technorati
Reply With Quote
Sponsored Links
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
displaying string jamborta AWT / Swing 6 01-23-2008 09:15 PM
setting system clocks time pks New To Java 0 01-10-2008 07:09 AM
Displaying charts in a jsp Priyanka Java Servlet 1 11-16-2007 12:59 PM
Images not displaying in JSP in IE7 chadscc Advanced Java 0 11-13-2007 05:24 PM
error message on jsp sandor Web Frameworks 1 04-11-2007 04:10 AM


All times are GMT +3. The time now is 09:16 PM.


VBulletin, Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2006 - 2007, www.java-forums.org