Forum Discussion
Visualization (Buttons and Slicers)
- 1 year ago
You could just create another conditional formatting measure but this time should be applied to the callout value of the buttons.
Slicer Highlight Color = IF ( SELECTEDVALUE ( MonthsOnly[Month Short] ) IN VALUES ( Dates[Month Short] ), "white" --#ffffff for hexadecimal )
Hi aziffarhan Are the columns coming from the same table? If so, selecting a value in any of the slicers should crossfilter the others unless visual interactions between them have been disabled. If the columns are from different tables, it can cause issues with filtering behavior. As a best practice, use a dedicated date or calendar table that includes all relevant date components (such as date, year, month, quarter, day, week number, etc.).
- aziffarhan1 year agoRegular Visitor
Hi danextian, thank you so much for your help! I really appreciate it.
There are a few things I still need help with.
Firstly, all the columns I’m using are from the same table. I’ve already created a Date Hierarchy consisting of Year, Quarter, Month, and Day.
What I’d like to achieve is the following behavior:
- When a user selects a Quarter (e.g., Q2), the respective Months within that quarter — April, May, and June — should also be automatically selected or highlighted.
- Similarly, when a user selects a Month (e.g., June), the corresponding Quarter (in this case, Q2) should also be selected or highlighted, even if only one month from that quarter is selected.
Is there a way to implement this kind of synchronized selection behavior in Power BI? I’d really appreciate any guidance or suggestions you can offer.
Thanks again!
- danextian1 year agoSuper User
Have you checked if visual interactions are enabled for those slicers? With or without hierarchy, as long as the interaction is enabled, you will get the same behaviour as in the image in my initital response. Also, please check if indeed the columns are from the same table - it could be a column with the same name but from another table.
- aziffarhan1 year agoRegular Visitor
Hi danextian, thanks again for your help!
The interactions are currently disabled, and there are a few reasons why I chose to do that.
I want the Month slicers to be selectable, not just displayed after clicking on a Quarter. At the same time, I need all buttons/slicers to be visible at all times. For example, when I select Q1, I want Jan, Feb, and Mar to be highlighted or selected, but I don’t want the other months to be hidden. I want all months to remain visible, regardless of the selection.
I’d really appreciate your help in figuring out how to achieve this behavior. Also just to add, a feature where I can select any months that I want without having to select a quarter is also needed. Whenever the user select a month, the respective quarter will also be selected, while the other quarter will be shown but not selected.
Feel free to let me know if more context is needed for your understanding.Thank you!