Call Value from Another Cell

  • I have a report that has some fairly complex calculations that total revenue. I now want to use the values from those calculations in other cells. How can I reference those cells in a formula?

    Suppose I have three cells in the header section of my report. (The actual expression is several lines long. I've used a basic SUM statement to keep it simple.)

    TEXTBOX1 Expression

    =sum(Fields!Green.Value)

    TEXTBOX2 expression

    =sum(Fields!Red.Value)

    Now I want TEXTBOX3 to use the values of 1 and 2.

    TEXTBOX3 expression

    =textbox1.value/textbox2.value

    I do not want to retype the formulas for 1 and 2 into 3. It would just increase the places I need to make changes if a core formula changes.

    Rob

  • I think you can use the ReportItems Collection. So the expression, using your example below, would be:

    ReportItems!TextBox1.Value/ReportItems!TextBox2.Value

  • Jack Corbett (9/8/2008)


    I think you can use the ReportItems Collection. So the expression, using your example below, would be:

    ReportItems!TextBox1.Value/ReportItems!TextBox2.Value

    I could remember reading about the ReportItems collection but could not find a reference to it. BOL doesn't contain this kind of information and my efforts at googling didn't find what I needed.

    Thank you.

    Rob

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply