little problem with FieldByName
From: Guillem (keinname_at_eresmas.net)
Date: 09/22/04
- Next message: Joe Pettit: "Tadoconnection and UDL file"
- Previous message: Viatcheslav V. Vassiliev: "Re: little problem with FieldByName"
- Next in thread: Viatcheslav V. Vassiliev: "Re: little problem with FieldByName"
- Reply: Viatcheslav V. Vassiliev: "Re: little problem with FieldByName"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: Wed, 22 Sep 2004 18:10:53 +0200
Hi,
Not sure if I should post this here, but today I got a problem when I tried
to get a DateTime using following sentence:
d: TDateTime;
...
d := ADODataset.FieldByName('date_field').AsDateTime;
Somehow the value for d would always be the same (0, the first value
available), whatever value was in the dataset field. Now, if I changed
AsDateTime for AsString all worked fine. This was really strange, so I
tried, just to check, to use AsString to get the date and then StrToDateTime
to convert it but, surprise, value was again 0!!
This is even more strange if I consider that in other libraries I have
implemented it just works fine (until now at least). Could it be because of
some corrupted component I've got in my DataModule? Or that Delphi has now
some corrupted file somewhere? Or (I don't think so) a bug?
Thanks for help and best regards
Guillem
- Next message: Joe Pettit: "Tadoconnection and UDL file"
- Previous message: Viatcheslav V. Vassiliev: "Re: little problem with FieldByName"
- Next in thread: Viatcheslav V. Vassiliev: "Re: little problem with FieldByName"
- Reply: Viatcheslav V. Vassiliev: "Re: little problem with FieldByName"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]