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 sizbut on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

The sting is non-numeric

Status
Not open for further replies.

Jefftopia

Programmer
Jul 30, 2002
104
US
I have a formula which is giving me the following error when I try to view the report.

Crystal Report Viewer
The string is non-numeric

Odd thing is the formula check out ok when I am in the formula editor. Here it is:

if IsDate(CStr({ado.SettleDate})) = True then {ado.SettleDate} else CDate({ado.SettleDate_calc})

Running-up on deadline. Help appreciated.
 
The formula doesn't allow for bad dates, try something like the following in the record selection formula->record to determine which rows are bad and the format:

not(IsDate(CStr({ado.SettleDate})))

Then you can properly code for the exceptions, as in:

if not(IsDate(CStr({ado.SettleDate}))) then "Bad date format: "+totext({ado.SettleDate})
else
totext({ado.SettleDate_calc})

-k
 
Decided to make change to underlying table report is based on. Now I have a single date field in the underlying table. I even took your suggestion and constructed a query to check for bad dates in my table. Everything checked out ok but I am still getting the following error:

"The string in non-numeric"

I am lost on this one. It seems to me that at this point all I am trying to do is bring in a date field to my report and still am not get it to work.

Any suggestions or work-arounds appreciated.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top