SAP Knowledge Base Article - Public

1261259 - Formula Field evaluates to True or False, Should be a different value type

Symptom

  • Formula evaluates to True or false, when expecting the value of the variable to be displayed

Reproducing the Issue

  • Environment
    • All versions of Crystal Report
    • Crystal Reports formula - Crystal Syntax
  • Steps to Reproduce
    1. variable declared, for example numbervar VariableOne
    2. Value is set by another field, for example VariableOne := {Table1.Field1}
    3. User forgets to add the : in the statement, so the formula actually reads VariableOne = {Table1.Field1}
    4. This formula would evaluate to true

Cause

  • := sets a new value
  • = only evaluates

Resolution

  • Add the : before the =

Keywords

Formula not evaluating correctly, error true, error false, incorrect value displayed, false, true , KBA , BI-RA-CR , Crystal Reports designer or Business View Manager , Problem

Product

Crystal Reports 2008 V0 ; SAP Crystal Reports 10.0 ; SAP Crystal Reports XI ; SAP Crystal Reports XI R2