JFRAME, continually pool database -refresh window

Posted on 2003-02-20
Medium Priority
Last Modified: 2012-08-13

I have a JFRAME and wish to access my msaccess db using some already written code.

I want the every minute to execute some code to display users logged in to a database - data stored in a table.

The code I've written works fine, to populate the JFRAME when its first run but i want to refresh the results - here I'm not to sure what to do.

Any help greatly appreciated

Question by:bluedingo
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions

Accepted Solution

membersh earned 250 total points
ID: 7986722
Have u tried thread approach ? Put code that connects to ur msaccess in a thread & run it at regular intervals.
LVL 14

Expert Comment

by:Tommy Braas
ID: 7987918
You could add a button to do the refresh at first, just to make sure that updating the UI works as expected. Then you should follow membersh's suggestion of creating a timer thread that reads the db every once in a while.

Featured Post

On Demand Webinar: Networking for the Cloud Era

Did you know SD-WANs can improve network connectivity? Check out this webinar to learn how an SD-WAN simplified, one-click tool can help you migrate and manage data in the cloud.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

For beginner Java programmers or at least those new to the Eclipse IDE, the following tutorial will show some (four) ways in which you can import your Java projects to your Eclipse workbench. Introduction While learning Java can be done with…
By the end of 1980s, object oriented programming using languages like C++, Simula69 and ObjectPascal gained momentum. It looked like programmers finally found the perfect language. C++ successfully combined the object oriented principles of Simula w…
Viewers learn about the third conditional statement “else if” and use it in an example program. Then additional information about conditional statements is provided, covering the topic thoroughly. Viewers learn about the third conditional statement …
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.
Suggested Courses
Course of the Month10 days, 16 hours left to enroll

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question