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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
LortT
Frequent Visitor

Hidden visuals setting data

Hello every one,

I create a custom visual and consult code from sampleBarChart in this link github.
https://github.com/microsoft/PowerBI-visuals-sampleBarChart/tree/condFormat/Tutorial
And I have a problem: I created a setting to be able to store my persist data. Let's say it is General View. I want it to not show up on the screen and work normally. But when I hide it, I can't get data from it anymore. How should I do it?

LortT_0-1733888765255.png

LortT_1-1733889100349.pngLortT_2-1733889158365.png

 

 

1 ACCEPTED SOLUTION
dm-p
Super User
Super User

Hi @LortT,

 

When you say 'hide,' do you mean remove/comment out as per your screenshot? If so, this will not populate the formatting model and will be inaccessible, as you have experienced.

 

If you are using powerbi-visuals-utils-formattingmodel to manage your formatting model, you can add and set the visible property of your settings class that represents the CompositeCard to false (while the rest of your code isn't available in OP, I would assume that your GeneralViewCardSettings class extends CompositeCard). By setting the visibility, your model is still processed as intended (and the property is therefore available for persistence/retrieval).

Regards,

 

Daniel





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

Proud to be a Super User!


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




View solution in original post

5 REPLIES 5
v-mdharahman
Community Support
Community Support

Hi @LortT,

May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

Thank you.

v-mdharahman
Community Support
Community Support

Hi @LortT,

We haven’t heard back from you for some time, so just following up to our previous message. We hope your issue has been resolved.

If the solution we provided has worked for you, kindly mark it as the accepted solution. Your feedback is important to us, Looking forward to your response. 

 

Thank you for being a valued member of the Microsoft Fabric Community Forum!

dm-p
Super User
Super User

Hi @LortT,

 

When you say 'hide,' do you mean remove/comment out as per your screenshot? If so, this will not populate the formatting model and will be inaccessible, as you have experienced.

 

If you are using powerbi-visuals-utils-formattingmodel to manage your formatting model, you can add and set the visible property of your settings class that represents the CompositeCard to false (while the rest of your code isn't available in OP, I would assume that your GeneralViewCardSettings class extends CompositeCard). By setting the visibility, your model is still processed as intended (and the property is therefore available for persistence/retrieval).

Regards,

 

Daniel





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

Proud to be a Super User!


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




v-mdharahman
Community Support
Community Support

Hi @LortT,

As we haven’t heard back from you, so just following up to our previous message. We hope your issue has been resolved.

If the solution we provided has worked for you, kindly mark it as the accepted solution. Your feedback is important to us, Looking forward to your response.

 

Thank you for being a valued member of the Microsoft Fabric Community Forum!

v-mdharahman
Community Support
Community Support

Hi @LortT,

Thanks for reaching out to the Microsoft fabric community forum.

Can you please provide some more details on what visual you were using? To address your issue of persisted data being inaccessible when hidden in a custom Power BI visual, it's important to understand how Power BI's properties and persistence mechanisms work.

 

Thank you. 

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

Find out what's new and trending in the Fabric community.

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.