Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi everyone, I'm currently trying to add a filter to my report where users can click on and select which fields will be included/excluded in the Stacked Area Chart visual I have in my report. I've sketched my desired situation on the following picture.
As shown on the picture I'd like to add a filter on the left side in which a user could click on a field e.g. "Website - Pageviews" or "Facebook - Post Impressions", and this would then select/deselect the fields that are included in the visual that I have on this page. I thought this would be a pretty straightforward thing to do, but after messing around in Power BI for a while I have no clue how one could easily do this. I googled this and skimmed through various videos on Power BI filters but so far I haven't come across something that would exclude a field completely from a visual, instead of just filtering data within the fields that are in the visual.
Solved! Go to Solution.
Hi @jensvanbellen ,
As I can see from your screenshot, you created a measure for each field in sclier and put them in values, the filter was fixed in measure , so you can't use slicer directly to filter legned.
I suggest you create a summary table union all the measure into one table(without your sample data ,I cannot provide a detailed formula). You can refer to my post in https://community.powerbi.com/t5/Desktop/Multi-Line-Diagram-to-compare-plants-with-categories/td-p/1...
If you need further help, please show me your sample data by onedrive for business.
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Dedmon Dai
Hi @jensvanbellen ,
As I can see from your screenshot, you created a measure for each field in sclier and put them in values, the filter was fixed in measure , so you can't use slicer directly to filter legned.
I suggest you create a summary table union all the measure into one table(without your sample data ,I cannot provide a detailed formula). You can refer to my post in https://community.powerbi.com/t5/Desktop/Multi-Line-Diagram-to-compare-plants-with-categories/td-p/1...
If you need further help, please show me your sample data by onedrive for business.
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Best Regards,
Dedmon Dai
Hi @v-deddai1-msft, thanks for your reply. In the meantime I build another solution as well that brings me close to what I initially wanted to accomplish. I made a new table with the Power Query Editor with the listed metrics I wanted the users to select and a key, something like this:
Metric | Key |
Website sessions | 1 |
Facebook post impressions | 2 |
etc. | etc. |
Then I added a slicer to the page with the graph where the user can select the Metric from fore-mentioned table. Next I created a new measure in which I used the SWITCH() function to switch out the variable depending on which Metric (and thus Key) the user chose in the slicer. I then use this new measure for the graph I have on the page. The only thing with this now is that so far I can only manage to display one metric at a time in the graph...
Thanks for your solution, I will try that as well! 😃
The result looks like this.
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
113 | |
99 | |
80 | |
70 | |
59 |
User | Count |
---|---|
149 | |
114 | |
107 | |
89 | |
67 |