This week's book giveaway is in the Big Data forum.
We're giving away four copies of Elasticsearch in Action and have Radu Gheorghe & Matthew Lee Hinman on-line!
See this thread for details.
The moose likes Beginning Java and the fly likes Date format Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Elasticsearch in Action this week in the Big Data forum!
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "Date format " Watch "Date format " New topic
Author

Date format

sivakumar panchu
Greenhorn

Joined: Jul 18, 2007
Posts: 20
Hi,

I want to know how to get the date format of particular country.

Based on countrycode or language code.
Amit Ghorpade
Bartender

Joined: Jun 06, 2007
Posts: 2753
    
    9

Use the DateFormat class.


Hope this helps


SCJP, SCWCD.
|Asking Good Questions|
Santhosh Kumar
Ranch Hand

Joined: Nov 07, 2000
Posts: 242
I'm not sure if there is any predefined 'format string' constants in Java API but sure you can get anything you want by defining your own formats. This Wikipedia article may come in handy.
Mark Vedder
Ranch Hand

Joined: Dec 17, 2003
Posts: 624

The SimpleDateFormat implementation of the DateFormat class Amit mentioned can change the formatting based on the Locale. See the Java Tutorial pages on the Formatting Dates and Times for more information.
sivakumar panchu
Greenhorn

Joined: Jul 18, 2007
Posts: 20
Thank you
 
I agree. Here's the link: http://kickstarter.com/rocket-mass-heater
 
subject: Date format