• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Paul Clapham
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Roland Mueller
  • Piet Souris
Bartenders:

Date Problems

 
Ranch Hand
Posts: 495
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hello,
I am trying to convert this Date Format "Mon May 01 18:00:00 EDT 2006" into"5/01/2006 6:00 PM", Does any one have an Idea
 
Ranch Hand
Posts: 62
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

Check out the Sun internationalisation tutorial, particularly the part for date formatting.

Good luck

Ramen
 
Ranch Hand
Posts: 135
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Reading between the lines, it sounds like your question is really "how do I output the date value in format xxx?"

You may be confusing the date's value with its string representation, which are two different things. A Date (or practically any object, for that matter), can be represented as a string in an almost infinite number of ways. How you do that is controlled by a formatting class, as the other reply indicates. Hope this clarifies rather than obfuscates things.
 
reply
    Bookmark Topic Watch Topic
  • New Topic