Topic: Correct Syntax, Error in Report Generation Posted: 19 Nov 2008 at 10:16pm
Hi All,
I have encountered the following problem when generating the report in Java and have been stuck since.
The error I encountered was: =========== START ERROR
=========== Error in formula <fbt>. 'WhilePrintingRecords; ' The string is non-numeric. =========== END ERROR =========== =========== START FORMULA =========== WhilePrintingRecords; if {t_spinal_screening.fbt} = "p" then ( Local NumberVar overall_deg; if IsNumeric({t_spinal_screening.atr_t_degree}) then ( if ToNumber({t_spinal_screening.atr_t_degree})>overall_deg then overall_deg = ToNumber({t_spinal_screening.atr_t_degree}); ); if IsNumeric({t_spinal_screening.atr_l_degree}) then ( if ToNumber({t_spinal_screening.atr_l_degree})>overall_deg then overall_deg = ToNumber({t_spinal_screening.atr_l_degree}) ); if IsNumeric({t_spinal_screening.atr_tl_degree}) then ( if ToNumber({t_spinal_screening.atr_tl_degree})>overall_deg then overall_deg = ToNumber({t_spinal_screening.atr_tl_degree}) ); if overall_deg >=1 AND overall_deg <5 then ( "Positive - For review"; ); if ( ToNumber({t_spinal_screening.atr_l_degree}) >=5) then "Positive - For re-assessment"; ) else if {t_spinal_screening.fbt} <> "" then "Negative" else "" ========== END FORMULA ==========
t_spinal_screening.fbt - is a database text field, blank is allowed t_spinal_screening.atr_t_degree - is a database text field, blank is allowed t_spinal_screening.atr_t_degree - is a database text field, blank is allowed t_spinal_screening.atr_t_degree - is a database text field, blank is allowed.
I am using Crystal Reports 9, and the syntax check says that there is no problems.
Will appreciate any help here. Thanks! :D
UPDATE: ----------- Found the answer; it actually had to do with the statements below and their logic errors. God, without domain experts by my side, and as a beginner to Crystal Reports, it can be quite frustrating.
if ( ToNumber({t_spinal_screening.atr_l_degree}) >=5) then
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot delete your posts in this forum You cannot edit your posts in this forum You cannot create polls in this forum You cannot vote in polls in this forum