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 strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Total for Calculated Field 2

Status
Not open for further replies.

btamulis

IS-IT--Management
Sep 30, 2005
37
US
SRS Newbie........surviving so far

I need to total a calculated field. The calculated field is in a group recordset (not detail).

Here's my calculated field (Gross Margin)

=iif(Fields!TOTALDOLLARSINVOICEDMATCHED.Value > 0,
(Fields!SalesPrice.Value*Fields!SoldQty.Value)-(Fields!TOTALDOLLARSINVOICEDMATCHED.Value),
(Fields!SalesPrice.Value*Fields!SoldQty.Value)-(Fields!ReceivedCost.Value))

The calculated field works great. In Crystal we would insert a summary or running total - How do we handle in SRS?

Thanks in advance.......

Bron Tamulis, CPIM
Great Plains Mfg Consultant
 
I would create a variable to hold this...then simply add it to any group level that you want to see a sum.

=SUM(Fields!rptGrossMargin.Value)
 
Thanks for the reply........

The calculated field is not 'labeled' per se on my report. The Calculated field is simply an 'expression' in a textbox.

In my case the 'expression' is in textbox116. I tried to change your formula to refer to textbox116 but it didn't work.

In other words, I'm not familar with 'labeling' my expressions - thus, the report throws an error if I refer to GrossMargin or textbox116.

How do I 'declare' a variable/function that I can then refer to?

Does this make sense?

Thanks again.....your thoughts?

Bron

Bron Tamulis, CPIM
Great Plains Mfg Consultant
 
I'm saying you should create a variable...click on your dataset and choose Add to create a variable.
 
Add a calculated field to your dataset with that expression, and then sum it as checkai mentioned. Your original reference would simply say: =Fields!MyCalculatedFieldName.Value whereas your sum would be =SUM(Fields!MyCalculatedFieldName.Value).

 
Okay - I understand now - I didn't get the desired result but I understand why and I'll be able to tweek......

Thanks,

Bron

Bron Tamulis, CPIM
Great Plains Mfg Consultant
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top