Forum Discussion

Tan008's avatar
Tan008
New Member
1 year ago
Solved

Passing values to another page using drill trough

I have a field parameter slicer in Power BI set to multi-select mode. The slicer includes metrics like Canada_Profit, France_Profit, Germany_Profit, Maxico_Profit. Same using in newcard.   On the s...
  • v-csrikanth's avatar
    1 year ago

    Hi Tan008 

    To pass the selected country from your field parameter slicer to a drillthrough page, follow these steps:

    1. Create a Country Table: List all countries (e.g., Canada, France).
    2. Unpivot Your Data: If your data has separate columns for each country's profit (e.g., Canada_Profit, France_Profit), unpivot it in Power Query to have a "Country" and "Profit" column.
    3. Set Relationships: Link the Country table to your unpivoted data on the Country column.
    4. Create a Measure: Use a measure to select the appropriate profit based on the country:
      ************************************************

    text

    Selected Profit =

    SWITCH(

        TRUE(),

        SELECTEDVALUE('YourCountryTable'[Country]) = "Canada", SUM(YourTable[Canada_Profit]),

        SELECTEDVALUE('YourCountryTable'[Country]) = "France", SUM(YourTable[France_Profit]),

        BLANK()

    )
    ************************************************

    1. Configure Drill through: Add the "Country" field from your Country table to the drillthrough filters on your drillthrough page.
    2. Update Visuals: Use the "Selected Profit" measure in your visuals on both pages.

    This setup allows dynamic filtering based on the selected country and ensures proper drillthrough functionality. Let me know if you need further assistance!

    If the above information helps you, please give us a Kudos and marked the Accept as a solution.

    Best Regards,

    Community Support Team _ C Srikanth.