No, at this stage I have found an easy way around the problem without having to decode the date.
Dave. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Neven MacEwan Sent: Friday, 18 June 2004 1:24 p.m. To: NZ Borland Developers Group - Delphi List Subject: Re: [DUG] Date conversions David Have you googled for this it would be a common problem I'd implement it as an object that parsed the input string Neven MacEwan (B.E. E&E) Ph. 09 621 0001 Mob. 0274 749062 David O'Brien wrote: > I can't guarantee the format, only that it will be a human readable > date. No matter, I'll just work around it . > > Thanks, > > Dave. > > ------------------------------------------------------------------------ > > *From:* [EMAIL PROTECTED] > [mailto:[EMAIL PROTECTED] *On Behalf Of > [EMAIL PROTECTED] > *Sent:* Friday, 18 June 2004 12:33 p.m. > *To:* [EMAIL PROTECTED] > *Subject:* RE: [DUG] Date conversions > > If it is always going to be that format you can. > > Remove the first 5 chars and call VarToDateTime. > > procedure Tform1.Button1Click(Sender: TObject); > > var > > lDT: TDateTime; > > lDStr: String; > > begin > > lDStr := 'Fri, 18 Jun, 2004'; > > lDStr := Copy(lDStr, 6, Length(lDStr)); > > lDT := VarToDateTime(lDStr); > > TButton(Sender).Caption := FormatDateTime('dd mmm yyyy', lDT); > > end; > > -----Original Message----- > *From:* David O'Brien [mailto:[EMAIL PROTECTED] > *Sent:* 18 June 2004 10:08 AM > *To:* NZ Borland Developers Group - Delphi List > *Subject:* [DUG] Date conversions > > Hi all, > > Is there any easy way of converting a date string into a TDate? > > i.e. "Fri, 18 Jun, 2004" > > Dave. > >----------------------------------------------------------------------- - > >_______________________________________________ >Delphi mailing list >[EMAIL PROTECTED] >http://ns3.123.co.nz/mailman/listinfo/delphi > > _______________________________________________ Delphi mailing list [EMAIL PROTECTED] http://ns3.123.co.nz/mailman/listinfo/delphi _______________________________________________ Delphi mailing list [EMAIL PROTECTED] http://ns3.123.co.nz/mailman/listinfo/delphi
