🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

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

Re: String To Date

#15455
From: Jonathan
Date: Mon, 14 Jun 1999 00:00
32 lines
1227 bytes
why don't you try

Date myDate = new Date(<string>);



Geoff Marshall wrote in message <3762CD95.5B8F5AAC@fsbdial.co.uk>...
>As a new comer to JB can anybody help me convert a string to a date?
>
>I have tried
>
>Date myDate = Date(<string>);
>
>              --->  Error "Date(jaa.land.string) not found..."
>and also
>
>Date myDate = DateFormat.parse(string);
>
>              ---> Error "Variable DateFormat not found ..."
>
>
>I have included the following:
>   import java.io.*;
>   import java.util.*;
>   import java.lang.*;
>
>Also can anybody say what string formats are acceptable?  I would like
>to use d/mm/yyyy but could re-arrange these.
>
>Thanks in advance for any assistance,
>
>Geoff Marshall
Technical Details
Message-ID: <7k2fbs$h2i17@forums.borland.com>
Path: arc1-ca.pugleaf.net!unknown!not-for-mail
References: <3762CD95.5B8F5AAC@fsbdial.co.uk>

Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit
X-Google-Thread: f74b3,3d8746921d3fd1df
X-Google-Attributes: gidf74b3,public
From: "Jonathan" <plaskowj@logica.com>
Subject: Re: String To Date
Date: 1999/06/14
Message-ID: <7k2fbs$h2i17@forums.borland.com>
X-Deja-AN: 489366045
References: <3762CD95.5B8F5AAC@fsbdial.co.uk>
Organization: Another Netscape Collabra Server User
X-MimeOLE: Produced By Microsoft MimeOLE V4.72.3110.3
Newsgroups: borland.public.jbuilder.java.language