locked
Passing the total count to a parameter RRS feed

  • Question

  • Hi there, how can i pass the value of a count from a cell to a parameter so that i could that to calculate the percentage EX: (x/totcount)* 100.0 where x is the total count of the subcategory and totcount is the total count for the parent category. Thanks!!

    Saturday, April 18, 2015 12:36 AM

Answers

  • Hi jmbuena,

    According to your description, you want to count the parent category and subcategory, then perform division for those two values.

    In your scenario, you could add the expression within the subcategory group to calculate the percentage. Please refer to the steps below:
    1. Sample data for the dataset and report design.

    2. Select the forth column, and select Hide option in Column Visibility.
    3. Select the textbox which the expression exists, then right click to open the Text Box Properties. On Number tab, select the Percentage option.
    4. Preview the report.


    If you have any question, please feel free to ask.

    Best regards,
    Qiuyun Yu


    Qiuyun Yu
    TechNet Community Support


    Monday, April 20, 2015 9:11 AM

All replies

    • Dear Jmbuena,

    The ReportItems built-in collection is the set of text boxes from report items such as rows of a data region or text boxes on the report design surface.

    Row Item: Expression :

    =Format(CDbl((Fields!value.Value/ReportItems!total.Value)),"0.00%")

    Row Total : Expression:

    =Format(CDbl((SUM(Fields!value.Value)/ReportItems!total.Value)),"0.00%")

    Don't forget to mark helpful posts, and answers. It helps others to find relevant posts to the same question.


    Ricardo Lacerda



    Saturday, April 18, 2015 2:10 AM
  • Hi jmbuena,

    According to your description, you want to count the parent category and subcategory, then perform division for those two values.

    In your scenario, you could add the expression within the subcategory group to calculate the percentage. Please refer to the steps below:
    1. Sample data for the dataset and report design.

    2. Select the forth column, and select Hide option in Column Visibility.
    3. Select the textbox which the expression exists, then right click to open the Text Box Properties. On Number tab, select the Percentage option.
    4. Preview the report.


    If you have any question, please feel free to ask.

    Best regards,
    Qiuyun Yu


    Qiuyun Yu
    TechNet Community Support


    Monday, April 20, 2015 9:11 AM