Announcement

Collapse
No announcement yet.

Formula syntax error, any ideas on where?

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

  • Formula syntax error, any ideas on where?

    Hey guys, this throws 'Syntax' error, any ideas why? It wasn't before but right now causes formula to halt:

    ifThen(
    pricingPlanMismatchDirection=='Down',
    activePricingPlanAlert='<p><font color="#000000" style="background-color: rgb(255, 156, 0);">Pricing plan mismatch</font></p>';
    );

    ifThen(
    pricingPlanMismatchDirection=='Up',
    activePricingPlanAlert='<p><font color="#000000" style="background-color: rgb(148, 189, 123);">Pricing plan mismatch</font></p>';
    );​


    Thanks

  • #2
    Code:
    $s1 = string\concatenate('<p><font color="#000000" style="background-color: rgb(255, 156, 0);">Pricing plan mismatch</font></p>');
    
    $s2 = string\concatenate('<p><font color="#000000" style="background-color: rgb(148, 189, 123);">Pricing plan mismatch</font></p>');
    
    ifThen(pricingPlanMismatchDirection=='Down', activePricingPlanAlert=$s1);
    
    ifThen( pricingPlanMismatchDirection=='Up', activePricingPlanAlert= $s2);
    ​
    don't ask why :-)

    Comment


    • #3
      Syntax check is fine when tested on v8.2.5.

      Comment


      • Russ
        Russ commented
        Editing a comment
        hey, thanks

    • #4
      Or:

      ifThen(
      pricingPlanMismatchDirection=='Down',
      activePricingPlanAlert=('<p><font color="#000000" style="background-color: rgb(255, 156, 0);">Pricing plan mismatch</font></p>');
      );

      ifThen(
      pricingPlanMismatchDirection=='Up',
      activePricingPlanAlert=('<p><font color="#000000" style="background-color: rgb(148, 189, 123);">Pricing plan mismatch</font></p>');
      );​

      Comment


      • #5
        8.2.2 - error in sandbox
        Attached Files

        Comment


        • #6
          With brackets around html code string - all ok
          Attached Files

          Comment


          • #7
            May be helpfull this error:
            Attached Files

            Comment


            • dimyy
              dimyy commented
              Editing a comment
              Minimal expression with error:
              $s1 = 'c=';

              Without error:
              $s1 = ('c=');

          • #8
            dude, thanks!!
            dimyy

            Comment


            • #9
              There was a bug in 8.2 which already is fixed. Maybe it's it.

              Comment

              Working...
              X