Forum Discussion
Custom Visual: Slicer selection display won't stay when page changes. (Visuals will reload)
- 6 years ago
Hi,
You are right, you can restore filter from update options.
If you use API 2.2 or higher, you will be able to read property jsonFilters from Options parameter inside Update method.
Kind Regards,
Evgenii Elkin,
Software Engineer
Microsoft Power BI Custom Visuals
[email protected]
Hi,
How do you pick the data in the slicer, through a Selction mechanism or Filter API?
If you work with a slicer it is recommended to use the second option.
Also, every time when you change the size of a visual, the Constructor woun't be called, only Update method will be.
Kind Regards,
Evgenii Elkin,
Software Engineer
Microsoft Power BI Custom Visuals
[email protected]
- cantoneye6 years agoFrequent Visitor
Hi Evgenii,
I use Filter API. So I have no problem with the filter even though the page changes and the visual reload, the data is still filtered. However, the visual needs to display which is filtered. When page changes or the dashboard refresh, I think the visual will reload and the Constructor will be called. I believe something must be done in the Constructor to call back my previous status.
- v-evelk6 years agoMicrosoft Employee
Hi,
You are right, you can restore filter from update options.
If you use API 2.2 or higher, you will be able to read property jsonFilters from Options parameter inside Update method.
Kind Regards,
Evgenii Elkin,
Software Engineer
Microsoft Power BI Custom Visuals
[email protected]- cantoneye6 years agoFrequent Visitor
Thanks for your help!! It works now.