0
votes
reporting services - How sum 'Tablix Column Values in a textbox' in SSRS - Stack Overflow
Asked
Viewed 3k times
0

In SSRS, I've tablix that is grouped by Products,as below:

Product | Billings

ABC     | 15
ABC     | 20
XYZ     | 35

My business requirements are to get total billings in a separate textbox. I tried as below (Textbox2 is the tablix textbox for billings):

=Sum(ReportItems!Textbox2.value)

But it throws error:

The Value Expression for the textbox 'Textbox3' refers to the report item 'Textbox2'. Report Items Expression can only refer to other report items within the same grouping scope or a containing grouping scope.`

I need help on this to get it done. Thanks in Advance

2
  • so are you looking to get a sum for product ABC and then XYZ etc? are you using SQL for your datasets?
    – Harry
    Mar 31 2019 at 20:49
  • no that was fetchXML based queries
    – Mohsin A.
    Apr 1 2019 at 6:42
0

Refering to a report item whithin a group can only be done within the same group. Your error description says it as well.

But you dont need to refer to this report item, just use the field from the dataset in the textbox again.

For the total billings, just add a textbox to your report and write the following expression:

=Sum(Fields!Billings.Value)

This will give you the overall total value (without the Product grouping).

1
  • yes, that is true and that is what I found after lot of hours before and after posting this question.
    – Mohsin A.
    Apr 1 2019 at 6:42
0

In design view, right mouse click product group, select add total after.

    Your Answer

    By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

    Not the answer you're looking for? Browse other questions tagged or ask your own question.

     
    2
    so are you looking to get a sum for product ABC and then XYZ etc? are you using SQL for your datasets?Harry
    no that was fetchXML based queriesMohsin A.

    2 Answers

    0
    votes

    Refering to a report item whithin a group can only be done within the same group. Your error description says it as well.

    But you dont need to refer to this report item, just use the field from the dataset in the textbox again.

    For the total billings, just add a textbox to your report and write the following expression:

    =Sum(Fields!Billings.Value)
    

    This will give you the overall total value (without the Product grouping).

    0
    votes

    In design view, right mouse click product group, select add total after.