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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
LukasSchlechter
Frequent Visitor

Visuals

Update methode isnt loading when im updating my visual.

 

I am trying to Create my own Visuals and im a bit new to the whole Power-bi/ Visual things.

I already set up a test-Dataset and a test Visual but im stuck to the point where all i do in the Update Methode isn´t working (the Dubugging is Hell on earth). I´ve tried to figure out where the update methode is called but without any success. in conclusion my update methode isnt called in any way...

Thx for the Help!

1 ACCEPTED SOLUTION
dm-p
Super User
Super User

Hi @LukasSchlechter,

Your visual's update() method is called when you have supplied the necessary conditions to satisfy your dataViewMapping; the exception being unless you are using supportsEmptyDataView in conjunction with supportsLandingPage to have no data binding. In this case, the update method will fire as soon as the visual is instantiated, and thereafter for the scenarios outlined in the diagram here, as expected.

If you've ruled out the data binding potentially being incorrect, the next thing I'd look at is seeing if any errors are being suppressed by the developer visual.

An easy way to investigate is to use a try/catch block to identify the error to see if anything's being suppressed, and possibly to step through using the debugger statement in your code before any suspect lines (or even right as the update method is triggered, just to confirm it. I often also use console.debug() in code I'm trying out to ensure that the right methods are being hit, without interruptng my workflow too much.

If you're sure that the above starting points are not applicable to you, then ideally you'll need to share your code with us (preferably as a repository, so we can verify the combination of packages, capabilities and code to see if there's anything else that stands out.

Regards,

Daniel





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)




View solution in original post

2 REPLIES 2
dm-p
Super User
Super User

Hi @LukasSchlechter,

Your visual's update() method is called when you have supplied the necessary conditions to satisfy your dataViewMapping; the exception being unless you are using supportsEmptyDataView in conjunction with supportsLandingPage to have no data binding. In this case, the update method will fire as soon as the visual is instantiated, and thereafter for the scenarios outlined in the diagram here, as expected.

If you've ruled out the data binding potentially being incorrect, the next thing I'd look at is seeing if any errors are being suppressed by the developer visual.

An easy way to investigate is to use a try/catch block to identify the error to see if anything's being suppressed, and possibly to step through using the debugger statement in your code before any suspect lines (or even right as the update method is triggered, just to confirm it. I often also use console.debug() in code I'm trying out to ensure that the right methods are being hit, without interruptng my workflow too much.

If you're sure that the above starting points are not applicable to you, then ideally you'll need to share your code with us (preferably as a repository, so we can verify the combination of packages, capabilities and code to see if there's anything else that stands out.

Regards,

Daniel





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)




i had issues with the dataViewMapping and now its working. The Exception handling was kinda helping but its not that ez to read if you just coded c#, python and java applications with good compiling programms.

Thank you for your Help!
Kind regards ,

Lukas

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!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

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