Home arrow static arrow Java Programming [Archive] - date format question
Warning: Creating default object from empty value in /www/htdocs/w008deb8/wiki/components/com_staticxt/staticxt.php on line 51
Java Programming [Archive] - date format question
This topic has 66 replies on 5 pages.    « Previous | 1 | 2 | 3 | 4 | 5 | Next »

Posts:7,258
Registered: 1/31/02
Re: date format question  
Aug 5, 2004 1:29 PM (reply 45 of 66)



 
hmmm - maybe you should try:

info@eatj.com
root@eatj.com
support@eatj.com

-- I often get confused and have to keep trying them 'till I find one that works. Sorry about that.
 

Posts:357
Registered: 8/5/04
Re: date format question  
Aug 5, 2004 2:18 PM (reply 46 of 66)



 
are you serious?

All these accounts might have CC: to master account, you know which that is?
 

Posts:357
Registered: 8/5/04
Re: date format question  
Aug 5, 2004 2:44 PM (reply 47 of 66)



 
OK - let's see.
 

Posts:24,036
Registered: 2/3/03
Re: date format question  
Aug 5, 2004 3:18 PM (reply 48 of 66)



 
I'm speechless.
 

Posts:357
Registered: 8/5/04
Re: date format question  
Aug 5, 2004 3:20 PM (reply 49 of 66)



 
hmmm - maybe you should try:

info@eatj.com
root@eatj.com
support@eatj.com

-- I often get confused and have to keep trying them
'till I find one that works. Sorry about that.

This good person seems to be on vacation.
 

Posts:27,518
Registered: 11/3/97
Re: date format question  
Aug 5, 2004 5:15 PM (reply 50 of 66)



 
Hijacking someone else's thread to repeatedly ask for
a email address?

Maybe no hurtin' nobody - but a bit rude, don't you
think?

You sound like a nice person. Do you mind sending me
your email?

You could supply your email address and a telephone number as well. That way the security conscious can verify the intent behind your request.
 

Posts:37,103
Registered: 3/30/99
Re: date format question  
Aug 5, 2004 5:20 PM (reply 51 of 66)



 
Hijacking someone else's thread to repeatedly ask
for
a email address?

Maybe no hurtin' nobody - but a bit rude, don't you
think?

You sound like a nice person. Do you mind sending me
your email?

You could supply your email address and a telephone
number as well. That way the security conscious can
verify the intent behind your request.

Home addres, mother's maiden name, bank account and credit card numbers and PINs. We don't mean any harm by asking, really.
 

Posts:10,967
Registered: 4/7/01
Re: date format question  
Aug 5, 2004 7:40 PM (reply 52 of 66)



 
This is a bit late to the thread, but it may help someone in the future. I saw DrClap's slick solution, and decided to look into locales, and the way they handle the date - something that I'd never done. In doing so, I found that the default format for the year can be 1, 2, or 4 digits.

I modified Paul's code so it works for all locales that DateFormat class handles; the only substantive change was to replace the pattern manipulation code with a regex: replaceAll("yy*", "yyyy").

The following demonstration code displays all valid locales, the default date pattern for each, and the modified pattern with the 4-digit year.
import java.text.*;import java.util.*; public class zc{    public static void main(String[] args)    {        Date dt = new Date();        Locale[] loc = DateFormat.getAvailableLocales();         for (int i = 0; i < loc.length; i++)        {            /*             *  System.out.print("/" +             *  loc[i].getDisplayLanguage() + "/" +             *  loc[i].getDisplayCountry() + "/" +             *  loc[i].getDisplayVariant() + "/ ");             */            SimpleDateFormat sdf = (SimpleDateFormat)                DateFormat.getDateInstance(DateFormat.SHORT, loc[i]);            String pat = sdf.toPattern();             System.out.print                (loc[i].getDisplayName() + " * " + pat + " * ");             String newPattern = pat.replaceAll("yy*", "yyyy");            sdf.applyPattern(newPattern);             System.out.println(sdf.format(dt));        }    }}
 

Posts:5,904
Registered: 04/03/99
Re: date format question  
Aug 6, 2004 8:48 AM (reply 53 of 66)



 

Well, Roboeater wants my email, and I would love to
see you turn purple - so here ya go:
webmaster@eatj.com

Do you think he's part of a class action lawsuit ? ;-)

Anyone with half a wit could find my email address from my account info page. I feel so rejected that roboloser can't be arsed.

Mind you, I've had 140,000 spam messages since January, so it might just be lost in the chaos...

D.
 

Posts:27,518
Registered: 11/3/97
Re: date format question  
Aug 6, 2004 9:04 AM (reply 54 of 66)



 

Well, Roboeater wants my email, and I would love to
see you turn purple - so here ya go:
webmaster@eatj.com

Do you think he's part of a class action lawsuit ? ;-)

Anyone with half a wit could find my email address
from my account info page. I feel so rejected that
roboloser can't be arsed.

Mind you, I've had 140,000 spam messages since
January, so it might just be lost in the chaos...

You count them?
 

Posts:37,103
Registered: 3/30/99
Re: date format question  
Aug 6, 2004 9:07 AM (reply 55 of 66)



 
Mind you, I've had 140,000 spam messages since
January, so it might just be lost in the chaos...

You count them?

He hire's yawmark's donkeys and llamas a spam accountants. Well, that's the cover he gives them.
 

Posts:24,036
Registered: 2/3/03
Re: date format question  
Aug 6, 2004 9:09 AM (reply 56 of 66)



 
Nothing counts spam like a Chilean Guanaco.
 

Posts:5,904
Registered: 04/03/99
Re: date format question  
Aug 6, 2004 9:44 AM (reply 57 of 66)



 

Actually I use an exceptionally well trained percheron. He also does my tax returns and gives exceptionally good backrubs.

Am I typing out loud again ? Oops...
 

Posts:31,095
Registered: 4/30/99
Re: date format question  
Aug 6, 2004 11:07 AM (reply 58 of 66)



 
We use moose here where I live to do tax returns. They also do a good job of filling in insurance claim forms. But you wouldn't want a backrub from a moose.
 

Posts:24,036
Registered: 2/3/03
Re: date format question  
Aug 6, 2004 11:08 AM (reply 59 of 66)



 
We use moose here where I live to do tax returns. They
also do a good job of filling in insurance claim
forms. But you wouldn't want a backrub from a moose.

A moose once bit my sister.
 
This topic has 66 replies on 5 pages.    « Previous | 1 | 2 | 3 | 4 | 5 | Next »