Board index » delphi » delphi 3 dates

delphi 3 dates

In delphi 1, I could save a datetime stamp field in a Paradox database
that happened to have a null value  to a double or extended variable,
attempt to process the record (and change its datetime stamp), and if
the process failed, reassign the datetime field to the null containing
variable... The datetime field in the Paradox field would then be null
again.  In Delphi 3 it becomes 12/30/1899 12:00a (i.e. 0) instead of
null.  Any ideas what changed and how best to handle it???

Thanks.

 

Re:delphi 3 dates


To assign null to any field type use

Table1.FieldByName('SomeField').Clear;

Bill

(Sorry but TeamB cannot answer support questions received via email.)
(To send me email for any other reason remove .nospam from my address.)

Re:delphi 3 dates


That's true but why is this happening.  To review, I'm saving the old
value (which happens to be null) to a variable, but when I put it back
in the Paradox date field it becomes 12/30/1899 12:00a???  This did not
happen in Delphi 1. Was there a documented change some place?

Quote
Bill Todd (TeamB) wrote:

> To assign null to any field type use

> Table1.FieldByName('SomeField').Clear;

> Bill

> (Sorry but TeamB cannot answer support questions received via email.)
> (To send me email for any other reason remove .nospam from my address.)

Other Threads