I have a report where I want to print all records for labels. For those
records that have a balance, I want to print 'Balance: 5.00' where 5.00
is whatever balance they have.
This is what I tried, and it prints
Balance: + (Orders.Balance)
If (Orders.Balance) > 0
Then 'Balance: + (Orders.Balance)'
I know that it's just printing what I'm telling it to, but how do I add
the actual field value to the string that I want to print? Please help
with syntax. Thanks!
Martin Walke - 30 Sep 2005 16:51 GMT
>I have a report where I want to print all records for labels. For those
> records that have a balance, I want to print 'Balance: 5.00' where 5.00
[quoted text clipped - 9 lines]
> the actual field value to the string that I want to print? Please help
> with syntax. Thanks!
Your field names should be surrounded by curly brackets {}, thus
"Balance: " + {Orders.Balance}
If you use the "edit formula" wizard you can pick the field names from the
list and it will automatically insert them for you.
HTH
Martin
Jim Edgar - 30 Sep 2005 16:56 GMT
> I have a report where I want to print all records for labels. For those
> records that have a balance, I want to print 'Balance: 5.00' where 5.00
[quoted text clipped - 9 lines]
> the actual field value to the string that I want to print? Please help
> with syntax. Thanks!
Try removing the single quote from around orders.balance:
'Balance: ' + (Orders.Balance)
Jim Edgar
L Black - 30 Sep 2005 17:06 GMT
Yeah, that didn't work - i think because it won't add a number to a
string. This did the trick:
If {Orders.BALANCE} <> 0
THEN "Balance Due: $" + ToText({Orders.BALANCE},2)
Else ""
Thanks though!