Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations SkipVought on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Using Running Total Fields in Formulas?

Status
Not open for further replies.

tancan74

Technical User
Jun 19, 2001
41
0
0
US
My report contains many, many detail lines, per Group. In each of those detail lines, I have a currency field called "Returnable Value", a currency field called "Non-Returnable Value" and a string field called "Non-Returnable Code".
Now, we needed running totals on a pretty straight forward basis for the "Returnable Value" field, I got that one ok. The hard part is, the report needs to show a running total of the "Non-Returnable Value" FOR EACH VALUE of the string field "Non-Returnable Code". Ok, I got that part too, now, I need to have fields that show me the "Non-returnable Code" + corresponding Running Total field + Code definition text, and that field should not display at all if the running total field for that code is empty, or zero.
I tried doing this in a formula:
"1" + {RunningTotalField1} + "blah blah description"

I keep getting an error saying that a string is expected just before that running total field. Does that mean you cannot refer to these types of fields in separate formula's?

Please help!
Tanya :)
 
Unless I don't understand the problem, I think you just need to this:
"1" + totext({RunningTotalField1}) + "blah blah description"
 
Argh, for some reason I was making this harder on myself than need be! That was perfect thank you!
 
The ToText property also has optional formatting arguments that you might want to include, otherwise the format of the number in the string may vary from computer to computer. Ken Hamady, On-site Custom Crystal Reports Training & Consulting
Public classes and individual training.
Guide to using Crystal in VB
tek@kenhamady.com
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top