Forum Discussion

wolfgang2's avatar
wolfgang2
Frequent Visitor
7 months ago
Solved

Custom Power BI Visual Not Updating After Repackaging – New version fails to replace old version

Hi everyone, I’m facing an issue with a Power BI custom visual update and wanted to see if anyone has experienced something similar. Here’s what’s happening: I made changes to an existing custom...
  • Ahmed-Elfeel's avatar
    7 months ago

    Hi wolfgang2,

    I hope you are doing well today ☺️❤️

     

    So what i will tell you is just a workaround (not an approach but try it):

     

    So Final Notes you should take care of it in the future:

    • Power BI aggressively caches visuals to improve load times
    • When you update an existing visual on a report page...Power BI may only call the visual update() method not its constructor leaving old states intact (This is why your logic needs to be in update())
    • Always increment the version number in your pbiviz.json file before packaging and uploading a new version

    I hope this works for you ☺️❤️

    if this post helps, then I would appreciate a thumbs up and mark it as the solution to help the other members find it more quickly.
  • v-hashadapu's avatar
    v-hashadapu
    7 months ago

    Hi wolfgang2 , Thank you for reaching out to the Microsoft Community Forum.

     

    From what you are saying, the About pane still shows the old visual version and none of the new logs or formatting metadata appear. That means the updated .pbiviz package is not being loaded at all for the existing visual instance, so your new update() code never executes.

     

    Power BI does not guarantee that visuals already placed on a report will be rebound to a newly uploaded package when the visual GUID remains the same. In that case, it can continue running the previously loaded bundle. Creating a new visual instance, switching visuals or reopening the report forces a fresh instantiation, which is why the new version works in those scenarios. There is currently no supported way to force an in place reload of an already placed custom visual. Removing and re-adding the visual (or changing the GUID during development) is the only reliable way to apply the updated package.