🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: borland.public.jbuilder.java.language
Article #16241

Re: help what's the current date

#16241
From: Tor Iver Wilhelmsen
Date: Thu, 11 Mar 1999 00:00
9 lines
895 bytes
DE DEUS Joao <joao.dedeus@ist.lu> writes:

> Yes I do and that gives me a date in this format dd/mm/yy.
> I need  the year in this way  " yyyy".

SimpleDateFormat myFormat = new SimpleDateFormat("dd/mm/yyyy");
StringBuffer dest = new StringBuffer("The date is: ");
FieldPosition dayPos = new FieldPosition(DateFormat.DATE_FIELD);
myFormat.format(new Date(), dest, dayPos);
Technical Details
Message-ID: <ubti0ifdl.fsf@sds.no>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <36E68075.7C5E8895@ist.lu> <36E6AAF7.5969@cwcom.co.uk> <36E76D53.5D512FD6@ist.lu>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,35e48ac0b6c11d6a
X-Google-Attributes: gidf74b3,public
From: Tor Iver Wilhelmsen <tor.wilhelmsen@sds.no>
Subject: Re: help what's the current date
Date: 1999/03/11
Message-ID: <ubti0ifdl.fsf@sds.no>
X-Deja-AN: 453723621
Sender: towi@SDSA1761
References: <36E68075.7C5E8895@ist.lu> <36E6AAF7.5969@cwcom.co.uk> <36E76D53.5D512FD6@ist.lu>
Organization: Another Netscape Collabra Server User
Newsgroups: borland.public.jbuilder.java.language