🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.jbuilder.java.api
2 messages
2 total messages Started by Nenko Ivanov Fri, 31 Jan 2003 14:56
Check for valid date format depending on current Locale
#681
Author: Nenko Ivanov
Date: Fri, 31 Jan 2003 14:56
5 lines
1244 bytes
Hi every one,
I want to check if a String value is a valid date reporesentation,
depending on the system locale.
How can I do that?
Thanks in advance.
Re: Check for valid date format depending on current Locale
#682
Author: John McGrath TeamB
Date: Fri, 31 Jan 2003 15:57
16 lines
1469 bytes
On Fri, 31 Jan 2003 16:56:16 +0200, Nenko Ivanov wrote:

> I want to check if a String value is a valid date reporesentation,
> depending on the system locale.

Use a DateFormat to parse the value.  If it throws a ParseException, it 
is invalid, otherwise it is valid.

-- 
Regards,

John McGrath [TeamB]

---------------------------------------------------
Before sending me e-mail, please read:
    http://www.JPMcGrath.net/newsgroups/e-mail.html
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads