Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

New Member




I am new to custom visual development and therefore  this query.


I have developed a simple custom slicer that, as expected, filters data based on checkbox selections. I am saving the selection state using persistProperties method but on saving the report or reloading, I lose the saved state and instead the last saved state is loaded. What might I be doing wrong here? The state persistence works fine as long as I am navigating within the report.



Any pointers on implementing persistProperties and why I am losing the state on save, would be appreciated.

Super User
Super User

Hi @pramodx,

It's not clear how you've set up your properties from the details in your question, but using persistProperties is not ideal in this case - for visuals that intend to function as a slicer, use the Visual Filters API and the approaches documented in this page to persist and restore selection state. Power BI will do a lot of the work for you and you then just need to manage the UI handling of restoring selected values from the update options' jsonFilters array into your elements.

If you're using this approach and using persistProperties for some other aspect of your visual's logic, then please share some details of your code, as well as your visual's capabilities, as it's very hard to debug these problems without having this context.



Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

My course: Introduction to Developing Power BI Visuals

On how to ask a technical question, if you really want an answer (courtesy of SQLBI)

Helpful resources

PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Dashboard in a day with date

Exclusive opportunity for Women!

Join us for a free, hands-on Microsoft workshop led by women trainers for women where you will learn how to build a Dashboard in a Day!

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors