cancel
Showing results for 
Search instead for 
Did you mean: 

Crsytal Report error in my REPLACE formula

Former Member
0 Kudos

I am trying to replace a word that if the text contains the word "Feet" then replace it with the text that is only first 15 characters of the text.

My formula:

Replace ({_WorkOrder.ConfigProptext}, like "*Feet*", Char(15) "Romano")

Error: **A number, currency amount, boolean, data, time, date-time, or string is expected here.**

How to fix it please.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

No need to use replace if that is what you want

Try

If {_WorkOrder.ConfigProptext} like "*Feet*" then left({_WorkOrder.ConfigProptext}, 15) else {_WorkOrder.ConfigProptext}

Ian

Answers (1)

Answers (1)

DellSC
Active Contributor
0 Kudos

If you're trying to replace the word "Feet" with "Romano", try this:

Replace ({_WorkOrder.ConfigProptext}, "Feet", "Romano")

-Dell