Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Fusilier
Helper III
Helper III

Clear all slicers button question

Hi,

I don't think this is possible, but thought I'd ask anyway.

Is there any way of formatting this button so it changes colour if any slicers are selected, therefore giving the user an indication that there are slicers selected?

1 ACCEPTED SOLUTION
shafiz_p
Super User
Super User

Hi @Fusilier  As I can understand that you want to change background color of Clear All Slicer button if slicer is selected. Yes this is possible. To acheive this, first create a measure to change color. 

ColorChange = IF(OR(ISFILTERED(Customer[Gender]),ISFILTERED(Customer[Education])), "Red", "White")

Now create Clear all slicer button. Go to formatting and go to fill option inside Button Style option. Click fx button, go to field value and select newly created measure. See Image below:
 
shafiz_p_0-1726307463563.png

 

 

And you are done. See the button color changed upon Gender selection. If I clear slicer, button color would white. See image below:

shafiz_p_1-1726307551037.png

 

 

Hope this helps!!

If this solved your problem, please accept it as a solution!!

 

Best Regards,
Shahariar Hafiz

View solution in original post

2 REPLIES 2
shafiz_p
Super User
Super User

Hi @Fusilier  As I can understand that you want to change background color of Clear All Slicer button if slicer is selected. Yes this is possible. To acheive this, first create a measure to change color. 

ColorChange = IF(OR(ISFILTERED(Customer[Gender]),ISFILTERED(Customer[Education])), "Red", "White")

Now create Clear all slicer button. Go to formatting and go to fill option inside Button Style option. Click fx button, go to field value and select newly created measure. See Image below:
 
shafiz_p_0-1726307463563.png

 

 

And you are done. See the button color changed upon Gender selection. If I clear slicer, button color would white. See image below:

shafiz_p_1-1726307551037.png

 

 

Hope this helps!!

If this solved your problem, please accept it as a solution!!

 

Best Regards,
Shahariar Hafiz

Thank you so much! Works like  dream.

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.