Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Crystal Report Date Problem with VFP table

Status
Not open for further replies.

dakotafox

Programmer
Apr 14, 2000
53
0
0
US
As a new user of Crystal Reports I am experiencing problems with date fields when working with a VFP7 table. If the date field contains a valid date value no problem, but if date field is empty it is reported/displayed as 12/30/1899 and then when the report is exported to Excel the same date field value is displayed in Excel as 01/00/1900. What formula syntax would identifiy this problem and correct the display?

Also the "convert null field values to default" checkbox is NOT checked.

Thank you in advance for the assistance
 
I'm guessing your database actually stores the date value "12/30/1899" to represent a null date (it could be a numeric zero, as the starting point of its internal date representation). One way to handle this is with a formula on the order of "if {date} = '12/30/1899' then "" else totext({date}) You will have to convert the date to text so that both parts of the if..then..else are the same type.
You may have to experiment to get the punctuation right.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top