posted 13 years ago
Sir/ Madam, i am facing a problem regarding how to refresh a JPanel in a timely manner. I have four JLabel in a JPanel which get value from database. My database has a table, where i have values in a timely manner within an interval of 1 hour. now i have to refresh my JLabel values i.e refresh JPanel so that as time changes i can display the new data from the database.
Now what i needed is that my JPanel need to be get refreshed automatically with the passing of time. When a day changes my JPanel get refreshed with date and time i.e if today is 13-03-2011 then next day i.e 14-03-2011 my JPanel need to be get refreshed automatically. I don't have much idea about timers and schedule. please help me and give me some suggestion so that i can continue............ please tel me what to write in action performed() method.
Please, help me in this regard. Any help from you will highly be appreciated. Thank you in advance.