Wrox Programmer Forums
| Search | Today's Posts | Mark Forums Read
Java Databases Discussion specific to working with Java Databases. For other Java topics, please see related Java forums. For database discussions not specific to Java, please see the Database category.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the Java Databases section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
  #1 (permalink)  
Old May 3rd, 2005, 05:52 PM
Registered User
Join Date: Apr 2005
Location: , , .
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Default Current Date

New to java. I'm creating application to pull data from my database.
When I open up my application I wanted to just click on a button to pull the most current data by the date. Can I have the results in JTextPane instead of JTable. Can someone give me example please thank you.

  #2 (permalink)  
Old May 5th, 2005, 03:09 AM
Friend of Wrox
Join Date: Jul 2004
Location: , , India.
Posts: 345
Thanks: 0
Thanked 1 Time in 1 Post
Send a message via MSN to gokul_blr Send a message via Yahoo to gokul_blr

I hope this example may be helpful to do better....

class AppletTimer
     javax.swing.Timer timer;
     String s;
     SimpleDateFormat timef = new SimpleDateFormat("HH:mm");
     //private Launch ll = new Launch();

     //public AppletTimer(final Applet ap)
     public AppletTimer(final JTextField tf)
             timer = new javax.swing.Timer(1000, new ActionListener() {
                 public void actionPerformed(ActionEvent e) {
                 s = timef.format(new Date(System.currentTimeMillis()));

Gokulan Ethiraj

Similar Threads
Thread Thread Starter Forum Replies Last Post
Current date format elayaraja.s XSLT 2 August 6th, 2008 03:08 AM
insert current date vsempoux XSLT 10 July 11th, 2008 07:31 AM
Current Date s15199d Reporting Services 2 April 3rd, 2006 12:38 AM
Getting the Current Date in XSLT kwilliams XSLT 2 November 30th, 2005 03:23 PM
Current Date?? morpheus SQL Server 2000 2 November 27th, 2003 04:21 PM

Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.